JS ES5, ES6 and Chrome Dev Tools(short)

Which JavaScript operator does not represent a loop?
for
while
if
for...in
How many times are we going to see an alert message?
 
for(var i=0;i<5;i++){
   alert("ping");
}
4
5
6
infinite
How many times are we going to see an alert message?
 
for(var i=0;i<=3+4;i++){
   alert("ping");
}
6
7
8
9
3
4
How many times are we going to see an alert message?
 
var i=0;
while(i < 3) {
   alert("ping");
   i++;
}
2
3
4
infinite
What will be the value of arr?
 
var arr = [1,2,3,4];
for(var i=0;i<3;i++) {
  arr[i]+= arr[i+1];
}
1,2,3,4
3,5,7,9
3,5,7,4
2,4,6,8
Which keyword is NOT used to declare a variable in JS
var
let
const
val
Which code will return an array of [1,3,5]?
[1,2,3].map((x,i) => {alert(x); return x+i;})
[1,2,3].map((x,i) => {x+x; x+i;})
[1,2,3].map((x,i) => x*i)
[1,2,3].map((x,i) => {x*i+1;})
const obj = {
   prop1:1,
   prop2:{
      arr:[1,2,3]
   },
   arr:[1,2,3]
};
 
We are going to use the object above for the following console output:
console.log(obj.prop1, obj.arr[1], obj.prop2.arr[0]);
 
You need to refactor(re-write) this line of code using ES6 object destructuring.
Which code from the options below is going to show an identical output(Choose as many answers as you want)?
const {prop1, arr:[a,b], prop2:{arr:[c]}} = obj; console.log(prop1, b, c);
const {prop1, arr:[a,b], prop2.arr:[c]} = obj; console.log(prop1, b, c);
const {prop1, arr:[b], prop2:{arr:[c]}} = obj; console.log(prop1, b, c);
const {prop1, {arr:[a,b]}, prop2:[arr:c]} = obj; console.log(prop1, b, c);
const {prop1, arr:[a,...rest], prop2:{arr:[...p]}} = obj; console.log(prop1, rest[0], p[0]);
const {prop1:p, arr:[a],arr:m,prop2:{arr:[c]}} = obj; console.log(p, m[0], c);
const obj = {
  prop1:{
    prop2:1
  },
  func: () => this.prop1.prop2 //Line #1
};
console.log(obj.func().bind(obj)); //Line #2
obj.func = function(){ //Line #3
  return this.prop1.prop2; //Line #4
}
console.log(obj.func.bind(this)()); //Line #5
const obj1 = obj;
obj = obj1; //Line #6
 
Specify ALL lines that will cause an error(only those lines, that throw an exception to the console). Pseudo line numbers are specified in the comment. This is a multiple choice answer
Line #1
Line #2
Line #3
Line #4
Line #5
Line #6
The team lead sent you a huge HTML page. One of it's blocks has a list of artists and a button, that will remove a random artist from the list. 
After inspecting the list in Chrome DevTools, you found out, that the HTML code looks like this:
 
<ul>
<li>
Artist 1
</li>
<li>
Artist 2
</li>
<li>
Artist 3
</li>
</ul>
How would you find, where is the Javascript code that removes an element from the list?
Select UL element and choose "Break on node removal" breakpoint
Select any LI element an choose "Break on node removal" breakpoint
Select UL element and choose "Break on subtree modifications" breakpoint
Select any LI element and choose "Break on attribute modifications" breakpoint
Select any LI element and choose "Break on subtree modifications" breakpoint
{"name":"JS ES5, ES6 and Chrome Dev Tools(short)", "url":"https://www.quiz-maker.com/QQJSCBF","txt":"Which JavaScript operator does not represent a loop?, How many times are we going to see an alert message?   for(var i=0;i<5;i++){    alert(\"ping\"); }, How many times are we going to see an alert message?   for(var i=0;i<=3+4;i++){    alert(\"ping\"); }","img":"https://www.quiz-maker.com/3012/images/ogquiz.png"}
Powered by: Quiz Maker