Finals Exam Flashcards
_____ are widely use in java programming
Strings
a ____ of characters
sequence
Strings are ____
Objects
The Java platform provides the String class to create and ____ strings
Manipulate
The string class is not a ___
Primitive Data Type
First Character starts at index
Zero (0)
The length starts at ___
one
Using the new keyword and ____ to create a string object
String constructor
The string literals in java are series of characters that will appear in output exactly as you _____
Entered
String literal are _____
Constant
Whenever the JVM encounters a string literal in a program it creates a string object with its ____
value
The string literals with the same contents share the ____
same memory location
while the constructed strings using the new keyword stored in _____
different memory location
The string method, equals() is used to _______ the content of two strings
compare
The _______ is used to compare the reference of two objects.
Relational Operator
The string class is ____ once it created its content cannot be change
immutable
Returns the character of string based on the ______
specific index
charAt()
Compares a string to another string.
The method returns 0 if the string is equal to other string
compareTo(string)
returns a new string concatenated with the value of the _____
parameter
returns true if this string and the specified string are equal
equals(string)
Considering the uppercase and lowercase to be the same
equalsIgnoreCase(string)
returns the first _____ of the specific string
indexOf(string)
returns the index of the last ______ of the specified string
lastIndexOf(string)