Variables
Data Types and Mode
Conditionals
Loops
ERROR
100

This is NOT a good variable name.

a) favoriteColor

b) favorite Color

c) favColor

b) favorite Color

100

2 would be considered what data type.

Number

100

what will the console log?


dogType='chihuahua'

if(dogType=='chihuahua'){

console.log('You have a small dog')}

else{console.log('bowwow')}

You have a small dog

100

what will the console log

for(i=0;i<7;i++){

console.log(i)}

0 1 2 3 4 5 6 

100

why would this show an error

favColor=='blue';

console.log(favColor)

two equal signs

200

This functions allows the user to input information.

a) console.log()

b) print()

c) prompt()

c) prompt()

200

'words' would be considered what data type

String

200

what will the console log

number = 2;

if((number-3)==0){

console.log('your number is the magic number')}

else if ((number-2)==0){

console.log('your number is almost the magic number')}

else{console.log('not even close')}

your number is almost the magic number

200

what will the console log

for(i=100;i<10;i++){

console.log(i)}

nothing (the initial i is too large so the loop breaks immediately)

200

why would this show an error

favColor = blue;

console.log(favColor)

blue is not a string

300

Given this code:

age=24;

age+=6;

console.log(age);

The console would say what.

30

300

A boolean data type can only be one of two options. The two options are this. 

true or false

300

what will the console log

number = 2;

if((number-3)<=0){

console.log('your number is a magic number')}

if((number-2)==0){

console.log('your number is almost the magic number')}

else{console.log('not even close')}

your number is a magic number

your number is almost the magic number

300

what will the console log

for(i=0;i<20;i++){

if(i%3==1){

console.log(i)}

}

1 4 7 13 16 19

300

why would this show an error

count=0;

for (i=0;i<10;i++){

count+=i

}

consolelog(count)

consolelog is missing . (console.log)

400

Given this code:

number1=3;

number2=5;

console.log(number1*number2);

The console would say what.

15

400

favColor = prompt("What's your favorite color?")

What datatype will favColor be after running and answering the question?;


string (any answer to prompt will be catagorized as a string, even if you answered '2')

400

What will the console log

number = 125;

if (number%5 == 0){

console.log('your number is a multiple of 5')}

if (number%2==0){

console.log('your number is even')}

if (number%3 == 0){

console.log('your number is divisible by 3')}


your number is a multiple of 5


400

what will the console log

count = 0;

for(i=0;i<10;i++){

if (i%3==0){

count *= i;

}

}


162

400

why would this show an error

if(favColor = 'blue'){

console.log('that's my fav color too')

}

=

500

Given this code:

number1 = 7;

number2 = 8;

console.log("number1*number2");

The console would say what.

number1*number2

500

156%20

16

500

if(num%3==0){

num = num/3;

num=num%4;

console.log(num)}

else {

num=num*2;

num=num%5;

console.log(num)}


what will the console log is num=31;

1

500

what will the console log

count = 0;

for(i=0;i<10;i++){

if (i%3==0){

count *= i;

}

else{

count+=i;

}}

1107

M
e
n
u