What is the use of tostring() method?

Correct Answer: If we print any object by using println() or print() methods The println() or print() methods internally calls tostring() method and prints the return value of toString() method

Discussion & Comments

No comments yet. Be the first to comment!
Join Discussion