re: Sets in JavaScript VIEW POST

FULL DISCUSSION
 

Is it correct to say that Set is like array, but with unique items only and Map is like object where keys might be of any type (not limited to strings and symbols)?

 

Well Set might look like an array but there are some notable differences. Apart from unique values, sets have different ways for initializing, accessing / adding / removing values.

code of conduct - report abuse