Strings

Quiz
•
Computers
•
11th Grade
•
Easy
Francesca [Student]
Used 3+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
append is a method in the StringBuffer class
True
False
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
append is a method in the String class
true
false
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
You cannot call a literal string's methods, as in "Hello".equals(str).
True
False
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Given
String word1 = "at";
String word2 = "Cat";
what is returned by word2.compareTo(word1)?
A negative integer
false
true
A positive integer
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The Character class contains the static method boolean isUpperCase(char ch).
True
False
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What happens if str.length() is 8 and you call str.charAt(8)?
charAt returns the random character that happens to be stored after the string.
You get a StringIndexOutOfBoundsException.
charAt returns the last character of str.
charAt returns -1.
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The length method returns 0 for an empty string.
True
False
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
Progamming - Java Syntax

Quiz
•
11th - 12th Grade
15 questions
Șiruri de caractere - funcții

Quiz
•
10th Grade - University
10 questions
10 câu kiểu xâu tiết 1

Quiz
•
11th Grade
10 questions
Introducing Python Strings

Quiz
•
11th Grade
12 questions
CodeHS 3.5 String Methods

Quiz
•
9th - 12th Grade
15 questions
Java Variables, Input and Output

Quiz
•
10th - 12th Grade
10 questions
Java Character and String class methods

Quiz
•
10th - 12th Grade
10 questions
Python Strings

Quiz
•
11th Grade
Popular Resources on Wayground
50 questions
Trivia 7/25

Quiz
•
12th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
11 questions
Negative Exponents

Quiz
•
7th - 8th Grade
12 questions
Exponent Expressions

Quiz
•
6th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
20 questions
One Step Equations All Operations

Quiz
•
6th - 7th Grade
18 questions
"A Quilt of a Country"

Quiz
•
9th Grade