
JavaScript (JS) Cheat Sheet
Flashcard
•
Computers
•
10th Grade
•
Easy
Joseph Armanious
Used 8+ times
FREE Resource
Student preview

122 questions
Show all answers
1.
FLASHCARD QUESTION
Front
How to include an external JavaScript file?
Back
<script src="filename.js"></script>
2.
FLASHCARD QUESTION
Front
What is the syntax for a function in JavaScript?
Back
function addNumbers(a, b) { return a + b; }
3.
FLASHCARD QUESTION
Front
How do you edit a DOM element in JavaScript?
Back
document.getElementById("elementID").innerHTML = "Hello World!";
4.
FLASHCARD QUESTION
Front
How to output data to the browser console in JavaScript?
Back
console.log(a);
5.
FLASHCARD QUESTION
Front
What is the syntax for a for loop in JavaScript?
Back
for (var i = 0; i < 10; i++) {
document.write(i + ": " + i*3 + "
");
}
6.
FLASHCARD QUESTION
Front
How do you declare a variable in JavaScript?
Back
var a; // variable a = 1; // assignment
7.
FLASHCARD QUESTION
Front
What is the purpose of 'use strict' in JavaScript?
Back
"use strict"; // Use strict mode to write secure code
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
70 questions
World History S1
Flashcard
•
10th Grade
170 questions
CSE - Semester 2 Review
Flashcard
•
7th - 12th Grade
54 questions
US Constitution Test
Flashcard
•
11th - 12th Grade
99 questions
United States Constitution and Citizenship Test
Flashcard
•
11th Grade
136 questions
Kapkore 1-5
Flashcard
•
Professional Development
141 questions
Civil Law and Its Features
Flashcard
•
University
151 questions
MJ US History CFE Exam Review
Flashcard
•
8th Grade - University
157 questions
Motivation, Emotion, Personality, and Social Psych 2025
Flashcard
•
11th Grade
Popular Resources on Wayground
8 questions
2 Step Word Problems
Quiz
•
KG - University
20 questions
Comparing Fractions
Quiz
•
4th Grade
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
10 questions
Latin Bases claus(clois,clos, clud, clus) and ped
Quiz
•
6th - 8th Grade
22 questions
fractions
Quiz
•
3rd Grade
7 questions
The Story of Books
Quiz
•
6th - 8th Grade