Question
a.
String object_Name = value;
b.
String object_name = new;
c.
String object_name= new value;
d.
String object_name= value new;
Posted under Object Oriented Programming
Engage with the Community - Add Your Comment
Confused About the Answer? Ask for Details Here.
Know the Explanation? Add it Here.
Q. How to declare an object of class String?
Similar Questions
Discover Related MCQs
Q. What does function length do in String class?
View solution
Q. Which is the function to get the character present at a particular index in the string?
View solution
Q. If only one parameter is passed to substring function then __________________
View solution
Q. If two index are given as argument to substring function then ___________________
View solution
Q. String class have a concat() function that is used to _____________________
View solution
Q. The function lastIndexOf() is used to ___________________
View solution
Q. Function equals() is _______________ and equalIgnoreCase() is _________________
View solution
Q. The compareTo() function is used to ________________
View solution
Q. String class provides function toUpper() to _____________________
View solution
Q. String trim() function is used to _______________________
View solution
Q. Function replace() accepts _____________ arguments.
View solution
Q. If two arguments are passed to the indexOf() function then ___________________
View solution
Q. The string class deals with string of only character type.
View solution
Suggested Topics
Are you eager to expand your knowledge beyond Object Oriented Programming? We've curated a selection of related categories that you might find intriguing.
Click on the categories below to discover a wealth of MCQs and enrich your understanding of Computer Science. Happy exploring!