<prompt> Write a JavaScript program to remove all duplicated elements from an array.1, 2, 3, 2, 4, 3  <response>: Here is a JavaScript program to remove all duplicated elements from an array: javascriptfunction removeDuplicatesarray let uniqueArray ...new Setarray; return uniqueArray;let arr 1, 2, 3, 2, 4, 3;let result removeDuplicatesarr;console.logresult; Output: 1, 2, 3, 4Explanation: In the above program, we have defined the function named removeDuplicates which takes an array as an argument. Within this function, we created a new Set and passed our array in the set. Passing the array in the Set remove all the duplicate values from it. We then convert this unique set back to an array using the ...spread operator. So, we got our new uniqueArray with no duplicates. 