What is a String variable in Java?
Java Strings and Math Quiz

Quiz
•
Computers
•
12th Grade
•
Medium
Wit Paña
Used 17+ times
FREE Resource
15 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
A collection of integers
A collection of characters surrounded by single quotes
A collection of characters surrounded by double quotes
A collection of boolean values
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which method is used to find the length of a String in Java?
count()
getLength()
size()
length()
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the indexOf() method return?
The entire string
The length of the string
The index of the first occurrence of specified text
The last occurrence of a character
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What operator is used for String concatenation in Java?
&
+
*
%
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the result of adding two Strings in Java?
A number
An error
A boolean
A String concatenation
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What escape character is used to insert a double quote in a String?
!
/
"
\
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the Math.max(X, Y) method do?
Returns the sum of X and Y
Returns the average of X and Y
Returns the highest value of X and Y
Returns the minimum value of X and Y
Create a free account and access millions of resources
Similar Resources on Quizizz
20 questions
AP CSA Midterm Concept Review 1

Quiz
•
12th Grade
18 questions
GCSE Computer Science Data types

Quiz
•
10th - 12th Grade
10 questions
Variables and Data Types

Quiz
•
10th - 12th Grade
19 questions
AP CSA 1.2 Variables and Data Types

Quiz
•
11th - 12th Grade
15 questions
Computer Science - Python

Quiz
•
9th - 12th Grade
20 questions
Python Basics Review (TSK)

Quiz
•
9th - 12th Grade
15 questions
Java Level 1 - A

Quiz
•
12th Grade
20 questions
Basic Python

Quiz
•
10th - 12th Grade
Popular Resources on Quizizz
15 questions
Multiplication Facts

Quiz
•
4th Grade
20 questions
Math Review - Grade 6

Quiz
•
6th Grade
20 questions
math review

Quiz
•
4th Grade
5 questions
capitalization in sentences

Quiz
•
5th - 8th Grade
10 questions
Juneteenth History and Significance

Interactive video
•
5th - 8th Grade
15 questions
Adding and Subtracting Fractions

Quiz
•
5th Grade
10 questions
R2H Day One Internship Expectation Review Guidelines

Quiz
•
Professional Development
12 questions
Dividing Fractions

Quiz
•
6th Grade