Help shape GoConqr. What should we add next?

Quiz

Javascript Variables

Rene Escobar 8 questions 3.0 (1 rating)

Take the quiz

Questions in this quiz (8)

  1. 1Which of these variables are not valid in Javascript?
    1. A4_colors
    2. BColor
    3. Ccolor
    4. D$color
  2. 2What happens when you declare a variable like
    var myVar;
    1. AThe variable value(output) is set to undefined
    2. BThe variable value(output) is set to null
  3. 3What are some of the main differences between null and undefined?
    1. ANull is used to tell the program that a value is truly empty
    2. BUnlike undefined, null is a falsy value
    3. Ctypeof null will return "Object" and typeof undefined returns "undefined"
  4. 4=== operator is less strict in terms of identifying equality than ==
    1. ATrue
    2. BFalse
  5. 5Variables created inside of a function can only be used within the function
    1. ATrue
    2. BFalse
  6. 6Which var world is considered to have a global scope?
    1. Avar date;
      function sayHello(){
      }
    2. Bfunction sayHello(){
      var date;
      }
  7. 7What will console log out in the following code?
    var part1 = "Team ";

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

    bam();
    1. ATreehouse
    2. BUndefined
    3. CTeam
  8. 8Declaring a variable without a var keyword will evaluate the variable with global scope
    1. ATrue
    2. BFalse

Information

Description
Javascript Quiz on Javascript Variables, created by Rene Escobar on 17/12/2014.
Language
English
Views
970
Rating
3.0 out of 5 · 1 rating
Rate this quiz
Rate this quiz

Feedback

What is it about?

What should we add next?