Register Now

Login

Lost Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

What is the string contained in s after following lines of Java code?
StringBuffer s new StringBuffer(“Hello”);
s.deleteCharAt(0);?

What is the string contained in s after following lines of Java code?
StringBuffer s new StringBuffer(“Hello”);
s.deleteCharAt(0);?
a) Hell
b) ello
c) Hel
d) llo

Answer: b
Explanation: deleteCharAt() method deletes the character at the specified index location and returns the resulting StringBuffer object.

Join The Discussion