6 years ago in java.lang Package

Which of these method of class String is used to obtain length of String object?

[A] get()
[B] Sizeof()
[C] lengthof()
[D] length()
Next Question

Overall Stats

Attempted 233
Correct 87
Incorrect 30
Viewed 116


Sairaj Pradip Devrukhkar - 2 months ago

length() is right

Meryem Onzy
Meryem Onzy - 1 week ago

Meryem Onzy from Casablanca, Morocco is saying length() is correct answer

Slindile Sithole
Slindile Sithole - 1 month ago

Slindile Sithole is saying length() is correct answer

sareddy pravalika
sareddy pravalika - 2 months ago

sareddy pravalika is saying Sizeof() is correct answer

Bharath - 3 months ago

Bharath from Hyderabad, India is saying length() is correct answer

Related Questions

Which of these is wrapper for simple data type float?

  • [A] float
  • [B] double
  • [C] Float
  • [D] Double

Which of the following will output a random with values only from 1 to 10?

  • [A] System.out.println(Math.round(Math.random()* 10));
  • [B] System.out.println(Math.round(Math.random() % 10));
  • [C] System.out.println(Math.random() *10);
  • [D] None of the above