Answer: string value : Questions « Utility Classes « SCJP
Java Source And Data Type
8.33.2.Answer: string value
F. Strings are immutable.
Which of the calls modifies the string s?
Answer: string value
Which is the output of the following code?
Answer: compare two strings
You can subclass java.lang.Math to create your own class(True/False).
Answer: Math class and subclass
Which is the output of the following code fragment?
After execution of line 2, sbuf still references the same instance.
Answer: StringBuffer reference
What is the output of the following code(string literal comparision)?
Answer: string literal comparision
What is the output of the following code(string literal and reference)?
Answer: string literal and reference
Which of the following are legal Java statements?
Answer: Integer wrapper
Is it a legal statement: List
theList = new Vector
Answer: generic class
Which of the following are legal(enhanced while loop)?
Answer: enhanced while loop
What is the legal clone() methods when subclassing Object?
Answer: clone method
Which of the following classes implement java.util.List?
Answer: java.util.List inheritance
Which of the following are methods of the java.util.SortedSet interface?
Which line of code tells a scanner called sc to use a single digit as a delimiter?
Answer: Scanner class
What happens when you try to compile and run this application?
How to compare two arrays
StringBuilder is generally faster than StringBuffer(True/False).
Answer: StringBuilder and StringBuffer
StringBuilder is threadsafe; StringBuffer is not(True/False).
Answer: StringBuilder and StringBuffer(2)
The Class class is the superclass of the Object class(True/False).
Answer: Class and Object
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.