const team = [
        'Mashrafi', 
        'Sakib', 
        'Mahmudullah', 
        'Mushfiq', 
        'Tamim', 
        'Rubel', 
        'Aftab', 
        'Razzaq', 
        'Rafiq'
    ];
const [captain, assistant, ...players] = team;
consoloe.log(players);

What is the output of consoloe.log(players); in your console?

  • Array ["Mahmudullah", "Mushfiq", "Tamim", "Rubel", "Aftab", "Razzaq", "Rafiq"]
const team = [
        'Mashrafi', 
        'Sakib', 
        'Mahmudullah', 
        'Mushfiq', 
        'Tamim', 
        'Rubel', 
        'Aftab', 
        'Razzaq', 
        'Rafiq'
    ];
const [captain, assistant, ...players] = team;
consoloe.log(captain);

What is the output of consoloe.log(captain); in your console?

  • Mashrafi

Considering the following snap of code, what is the expected result?

const gotNumber = 46;
if (gotNumber>45) {
    var division = 'Second Division';
}
console.log(`Division is ${division} by number ${gotNumber}`);
  • Division is Second Division by number 46

Considering the following snap of code, what is the expected result?

const gotNumber = 46;
if (gotNumber>45) {
    let division = 'Second Division';
}
console.log(`Division is ${division} by number ${gotNumber}`);
  • Error: division is not defined

Considering the following snap of code, what is the expected result?

let dogName = 'Tom';
let catName = 'Jerry';
[dogName, catName] = [catName, dogName];
console.log(`Dog name: ${dogName}`);
  • String output: Dog name: Jerry