Control Structures Quiz

Control Structures Quiz

8th Grade

12 Qs

quiz-placeholder

Similar activities

THE QUIZ

THE QUIZ

KG - University

8 Qs

JS Talks, Quiz #5

JS Talks, Quiz #5

1st - 12th Grade

15 Qs

Pseudocode and Flowcharts - Computer Science

Pseudocode and Flowcharts - Computer Science

KG - 12th Grade

15 Qs

Coding Conditionals

Coding Conditionals

6th - 8th Grade

10 Qs

Calculator

Calculator

2nd - 8th Grade

15 Qs

Moringa JavaScript Arrays

Moringa JavaScript Arrays

5th Grade - Professional Development

10 Qs

Doing Math in JavaScript

Doing Math in JavaScript

8th Grade

10 Qs

Introduction To Java: Hello World

Introduction To Java: Hello World

7th - 12th Grade

10 Qs

Control Structures Quiz

Control Structures Quiz

Assessment

Quiz

Computers

8th Grade

Medium

Created by

Aldo Chapa

Used 2+ times

FREE Resource

12 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct way to define a function in JavaScript?

function: myFunction() {}

function myFunction() {}

def myFunction() {}

function = myFunction() {}

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a Boolean value in JavaScript?

0

"true"

true

`"false"

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which logical operator represents "AND" in JavaScript?

&&

||

!

==

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of the following comparison in JavaScript: 10 == "10"`?

true

false

undefined

null

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will the following code output? ```javascript let x = 0; while (x < 3) { console.log(x); x++; } ```

0 1 2

1 2 3

0 1 2 3

1 2

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which statement is used to exit a loop prematurely in JavaScript?

exit

stop

break

end

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a valid function call in JavaScript?

myFunction;

myFunction[];

myFunction();

myFunction{}

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?