IT quiz
All questions
Sign in
Sign up
JavaScript
HTML
CSS
PostgreSQL
PHP
Linux
Git
Docker
SCSS
TypeScript
SQL
Vue
DNS
Go
frontend (web)
Redis
backend
Gitlab
CI/CD
Vite
webpack
Node.js
HTTP
Python
Kotlin
Nuxt
Question #195
Author:
admin
tags:
JavaScript
const set = new Set([1, 2, 3, 1, 2, 3]); const arr = [...set]; console.log(arr); // ???
What will be printed?
[[1, 2, 3, 1, 2, 3]]
[1, 1, 2, 2, 3, 3]
[1, 2, 3, 1, 2, 3]
[1, 2, 3]
Answer
Show explanation
A
Set
object stores unique values of any type.
Rate the difficulty of the question:
1
2
3
4
5
6
7
8
9
10
easy
hard
←
Previous question (JavaScript)
Next question (JavaScript)
→
Write new comment