Javascript Basic

Javascript Basic

9th - 12th Grade

20 Qs

quiz-placeholder

Similar activities

PPG 25 Feb 2022

PPG 25 Feb 2022

12th Grade

19 Qs

Text and Image representation

Text and Image representation

11th Grade

22 Qs

ความรู้เบื้องต้นการเขียนโปรแกรมภาษาซี

ความรู้เบื้องต้นการเขียนโปรแกรมภาษาซี

12th Grade

20 Qs

Quiz Informatika 9

Quiz Informatika 9

9th Grade

16 Qs

Standard Linux Commands

Standard Linux Commands

1st - 10th Grade

20 Qs

حاسب 1 نظري

حاسب 1 نظري

10th Grade

21 Qs

Dasar Komputer

Dasar Komputer

10th Grade

23 Qs

Quis Grade 5

Quis Grade 5

9th - 12th Grade

15 Qs

Javascript Basic

Javascript Basic

Assessment

Quiz

Computers

9th - 12th Grade

Practice Problem

Medium

Created by

iqbal yunanto

Used 33+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

20 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is a JavaScript variable?

A container that holds a value

A function that performs a task

A way to add styles to a website

A type of data

2.

MULTIPLE SELECT QUESTION

30 sec • 1 pt

How do you write a JavaScript string?

"Hello World!"

Hello World!

'Hello World!'

`Hello World!`

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the difference between = and == in JavaScript?

= assigns a value to a variable and == compares values

= compares values and == assigns a value to a variable

= and == are the same thing

= assigns a value to a variable and == assigns a value to a variable

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you create a JavaScript function?

create function myFunction() {}

new function myFunction() {}

myFunction() {}

function myFunction() {}

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you write a JavaScript alert?

alert = "Hello World!";

alert {Hello World!};

alert("Hello World!");

alert "Hello World!";

6.

MULTIPLE SELECT QUESTION

45 sec • 1 pt

How do you write a JavaScript comment?

# This is a comment

// This is a comment

/* This is a comment */

-- This is a comment

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you change the background color of an HTML element using JavaScript?

element.color = "red";

element.background = "red";

element.style.backgroundColor = "red";

element.setBackground("red");

Create a free account and access millions of resources

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?