Convert a String In C++ To Upper Case

后端 未结 30 1913
一个人的身影
一个人的身影 2020-11-22 05:25

How could one convert a string to upper case. The examples I have found from googling only have to deal with chars.

30条回答
  •  不要未来只要你来
    2020-11-22 06:00

    try the toupper() function (#include ). it accepts characters as arguments, strings are made up of characters, so you'll have to iterate over each individual character that when put together comprise the string

提交回复
热议问题