1.

What is the use of .capitalize method?(a) It capitalizes the entire string(b) It capitalize on the first letter of the string(c) It capitalize the strings which are in small case(d) All of the mentionedI got this question by my college director while I was bunking the class.I'd like to ask this question from Formatting String Methods in chapter Ruby Basics of Ruby

Answer»

The CORRECT choice is (b) It CAPITALIZE on the first LETTER of the string

Easy EXPLANATION: It capitalizes only the first letter.



Discussion

No Comment Found

Related InterviewSolutions