1.

If only one parameter is passed to substring function then __________________(a) It returns the character at the specified position(b) It returns the string of length 1 from the specified index(c) It returns the string from specified index till the end(d) It returns the string from starting of string till the specified index

Answer» The correct option is (c) It returns the string from specified index till the end

To explain I would say: The substring function returns a string value. The string is the substring starting from the specified index till the end. The substring function have to be called with the object of string class.


Discussion

No Comment Found

Related InterviewSolutions