logo
Search
showing results for - "javascript array destructuring"
Niko
23 Nov 2018
1let [a, b] = [9, 5]
2[b, a] = [a, b]
3console.log(a, b);
4//Expected output: 5,9
similar questions
how to destructuring array in javascript 3fobject destructuringobject destructuringjs destructuring explainedhow destructuring works in javascriptdestructuring in javascriptjavascript destructingobject destructuring examplearray map destructuringjs destructuringjavascript object destructingdestructuring objectsobject destructuring javascriptdestructuring javascriptarray destructuringdestructuring object in javascriptdestructuring objects jsobject destructuring to function parameters
queries leading to this page
array destructuring in javascriptarray destructuring 3ajavascript array destructuring
privacy policyterms of useinstagram
Crafted with  ♥  for everyone

sign in to continue
your answer for
you will get a confirmation link on this - you will have to click that for successful submission of your answer. we require this to keep the website free of spam, bots and unhelpful content
please ensure to add code which is syntactically corrent and executes properly
sign in to continue
ask question on maxinterview
you will get a confirmation link on this - you will have to click that for successful submission of your question. we require this to keep the website free of spam, bots and unhelpful content
please be clear, to the point and respectful
sign in to continue