1. Which keyword should be used to declare the static member functions?
Correct Answer is : static
2. The keyword static is used _______________
Correct Answer is : With declaration inside class and not with definition outside the class
3. The keyword static is used _______________
Correct Answer is : With declaration inside class and not with definition outside the class
4. Which among the following can’t be used to access the members in any way?
Correct Answer is : Single colon
5. Which among the following can’t be used to access the members in any way?
Correct Answer is : Single colon
6. We can use the static member functions and static data member __________________
Correct Answer is : Even if class object is not created
7. We can use the static member functions and static data member __________________
Correct Answer is : Even if class object is not created
8. The static data member _________________
Correct Answer is : Can’t be mutable
9. The static data member _________________
Correct Answer is : Can’t be mutable
10. If static data member are made inline, ______________
Correct Answer is : Those can be initialized within the class
11. If static data member are made inline, ______________
Correct Answer is : Those can be initialized within the class
12. Which is a true statement for object of String class?
Correct Answer is : Object are immutable
13. How to declare an object of class String?
Correct Answer is : String object_Name = value;
14. What does function length do in String class?
Correct Answer is : Returns length of string excluding null character
15. Which is the function to get the character present at a particular index in the string?
Correct Answer is : char charAt(index);
16. If only one parameter is passed to substring function then __________________
Correct Answer is : It returns the string from specified index till the end
17. If two index are given as argument to substring function then ___________________
Correct Answer is : String starting from first index and ending at second index position
18. String class have a concat() function that is used to _____________________
Correct Answer is : Append one string at end of another string
19. The function lastIndexOf() is used to ___________________
Correct Answer is : Get the index of last occurrence of specified character in argument
20. Function equals() is _______________ and equalIgnoreCase() is _________________
Correct Answer is : Case sensitive, Case insensitive