
JavaScript Strings
Authored by Mark Galesi
Computers
9th Grade
Used 15+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
12 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
var len = "jump it!".length;
What is the value of len?
8
7
9
6
This code does not compile.
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
var x = "quarantine".indexOf("a");
What is the value of x?
4
3
2
This code does not compile.
StringIndexOutOfBoundsException
3.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
var s = "whatever".substring(1,4);
What is the value of s?
"hate"
"hat"
"whate"
"what"
StringIndexOutOfBoundsException
4.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
var p = "Go Paw Patrol!".indexOf("p");
What is the value of p? (Case matters)
0
4
3
-1
This code will not compile.
5.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
var s = "cool cat".substring(6,"cool cat".length);
What is the value of s?
"cat"
"at"
"cool c"
This code does not compile.
StringIndexOutOfBoundsException
6.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
var s = "good job".substring(3, 9);
What is the value of s?
"d job"
"od job"
"d jo"
"od jo"
StringIndexOutOfBoundsException
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which type of value is returned from the length function?
decimal
word
integer
true/false
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
10 questions
PUNCTUATION SPACING RULES
Quiz
•
9th - 12th Grade
10 questions
INTRODUCCION A LA PROGRAMACION
Quiz
•
6th Grade - University
10 questions
Programming Constructs
Quiz
•
5th - 11th Grade
15 questions
L3...JavaScript - Introducción
Quiz
•
9th Grade
11 questions
Threats to Data
Quiz
•
9th - 12th Grade
11 questions
HEALTH AND SAFETY 9
Quiz
•
7th - 9th Grade
15 questions
Quiz 1
Quiz
•
1st - 12th Grade
14 questions
LA5.C5: Branching and Subroutines
Quiz
•
9th Grade - University
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade