Question: Which is a valid declarations of a String?

Options

A : String s1 = null;

B : String s2 = 'null';

C : String s3 = (String) 'abc';

D : String s4 = (String) 'ufeed';

Click to view Correct Answer

Previous || Next

Language Fundamentals - General Questions more questions

Which one of the following will declare an array and....

Which three are valid declarations of a char?

Which is the valid declarations within an interface definition?

Which one is a valid declaration of a boolean?

Which three are valid declarations of a float?

What is the numerical range of a char?

Suppose that you would like to create an instance of....

Which class does not override the equals() and hashCode() methods,....

Which collection class allows you to grow or shrink its....

You need to store elements in a collection that guarantees....

Declarations and Access Control - General Questions more Online Exam Quiz

Declarations and Access Control - General Questions

Objects and Collections - General Questions

Threads - General Questions

Automobile Engineering - Part 1

Compressors, Gas Dynamics and Gas Turbines - Part 1

Engineering Materials - Part 1