Exam 7: Characters, Strings and the Stringbuilder
Exam 1: Creating Your First Java Classes76 Questions
Exam 2: Using Data81 Questions
Exam 3: Using Methods, Classes and Objects79 Questions
Exam 4: More Object Concepts84 Questions
Exam 5: Making Decisions80 Questions
Exam 6: Looping77 Questions
Exam 7: Characters, Strings and the Stringbuilder82 Questions
Exam 8: Arrays77 Questions
Exam 9: Advanced Array Concepts80 Questions
Exam 10: Introduction to Inheritance78 Questions
Exam 11: Advanced Inheritance Concepts78 Questions
Exam 12: Exception Handling79 Questions
Exam 13: File Input and Output78 Questions
Exam 14: Introduction to Swing Components79 Questions
Exam 15: Using Javafx and Scene Builder65 Questions
Select questions type
A ____ is a class for storing and manipulating changeable data that is composed of multiple characters.
(Multiple Choice)
4.9/5
(36)
The terms "literal string" and "string literal" have different meanings in Java programming.
(True/False)
4.8/5
(33)
Match each term with the correct statement below.
Premises:
Object that can't be changed
Responses:
immutable
parseDouble().
capacity
Correct Answer:
Premises:
Responses:
(Matching)
4.8/5
(41)
The String class ____ method evaluates the contents of two String objects to determine if they are equivalent.
(Multiple Choice)
4.9/5
(37)
yourCounty = "Clark"
yourCounty.startsWith("Cla")
What value will be returned by the startsWith() method? Explain how the startsWith() method deals with case sensitivity.
(Essay)
4.8/5
(45)
StringBuilder greeting = new StringBuilder("Hello, John");
char initial = greeting.charAt(7);
Using the above code and the charAt() method, what value will be assigned to the variable initial ?
(Essay)
4.8/5
(28)
StringBuilder greeting = new StringBuilder("Welcome home ");
phrase.insert(13, "Joe");
Using the above code and insert() method, describe how the phrase will appear after the code executes. How does the insert() method work?
(Essay)
4.8/5
(39)
Match each term with the correct statement below.
Premises:
Determines whether a specific character occurs within a String
Responses:
buffer
immutable
insert()
Correct Answer:
Premises:
Responses:
(Matching)
4.9/5
(34)
The methods of the Character class that begin with ____ return a character that has been converted to the stated format.
(Multiple Choice)
4.8/5
(34)
Match each term with the correct statement below.
Premises:
Memory block
Responses:
immutable
substring().
insert()
Correct Answer:
Premises:
Responses:
(Matching)
4.7/5
(33)
The ____ method requires an integer argument that indicates the position of the character at that position, starting at 0.
(Multiple Choice)
4.8/5
(29)
The StringBuffer class is more efficient than the StringBuilder class because it can execute multiple threads during program execution.
(True/False)
4.9/5
(34)
String greeting = "Welcome back";
Using the above statement, write the length() method that will return the length of the greeting String . Store the length in an integer named greetingLength .
(Essay)
4.9/5
(39)
If you try to use an index that is greater than 0 or less than the index of the last position in the StringBuilder object, you cause an error known as an exception and your program terminates.
(True/False)
4.9/5
(38)
Match each term with the correct statement below.
Premises:
Takes a String argument and returns its double value
Responses:
concatenation
setLength()
toLowerCase().
Correct Answer:
Premises:
Responses:
(Matching)
4.8/5
(43)
Explain what is needed to declare a String variable and provide an example.
(Essay)
4.9/5
(31)
String s and other objects that can't be changed are known as ____.
(Multiple Choice)
4.8/5
(32)
Showing 61 - 80 of 82
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)