Rene Escobar
Quiz por , criado more than 1 year ago

Javascript Quiz sobre Javascript Variables, criado por Rene Escobar em 17-12-2014.

736
0
0
Rene Escobar
Criado por Rene Escobar mais de 9 anos atrás
Fechar

Javascript Variables

Questão 1 de 8

1

Which of these variables are not valid in Javascript?

Selecione uma das seguintes:

  • 4_colors

  • Color

  • color

  • $color

Explicação

Questão 2 de 8

1

What happens when you declare a variable like
var myVar;

Selecione uma das seguintes:

  • The variable value(output) is set to undefined

  • The variable value(output) is set to null

Explicação

Questão 3 de 8

1

What are some of the main differences between null and undefined?

Selecione uma ou mais das seguintes:

  • Null is used to tell the program that a value is truly empty

  • Unlike undefined, null is a falsy value

  • typeof null will return "Object" and typeof undefined returns "undefined"

Explicação

Questão 4 de 8

1

=== operator is less strict in terms of identifying equality than ==

Selecione uma das opções:

  • VERDADEIRO
  • FALSO

Explicação

Questão 5 de 8

1

Variables created inside of a function can only be used within the function

Selecione uma das opções:

  • VERDADEIRO
  • FALSO

Explicação

Questão 6 de 8

1

Which var world is considered to have a global scope?

Selecione uma das seguintes:

  • var date;
    function sayHello(){
    }

  • function sayHello(){
    var date;
    }

Explicação

Questão 7 de 8

1

What will console log out in the following code?
var part1 = "Team ";

function bam() {
var part2 = "Treehouse";
console.log(part2);
}

bam();

Selecione uma das seguintes:

  • Treehouse

  • Undefined

  • Team

Explicação

Questão 8 de 8

1

Declaring a variable without a var keyword will evaluate the variable with global scope

Selecione uma das opções:

  • VERDADEIRO
  • FALSO

Explicação