How to use case insensitive strings? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How to use case insensitive strings?

If I were taking user input, what would I have to to make sure that capitalization of words does NOT matter?

30th Jun 2016, 5:17 PM
Micah Chaffin
Micah Chaffin - avatar
1 Answer
+ 1
after taking input... pass the string to the func tolower (str); this function reduces all the uppercase letters in the string to lower case. I don't remember the header for this func you may google it
30th Jun 2016, 5:23 PM
Mukul Kumar
Mukul Kumar - avatar