We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1ea3d84 commit c20a478Copy full SHA for c20a478
strings/upper.py
@@ -12,9 +12,9 @@ def upper(word: str) -> str:
12
'WH[]32'
13
"""
14
15
- # converting to ascii value int value and checking to see if char is a lower letter
16
- # if it is a capital letter it is getting shift by 32 which makes it a capital case
17
- # letter
+ # Converting to ascii value int value and checking to see if char is a lower letter
+ # if it is a lowercase letter it is getting shift by 32 which makes it an uppercase
+ # case letter
18
return "".join(chr(ord(char) - 32) if "a" <= char <= "z" else char for char in word)
19
20
0 commit comments