shift lowercase input chars to uppercase
This commit is contained in:
parent
f127a1a249
commit
431c198138
1
main.c
1
main.c
|
@ -63,6 +63,7 @@ int main() {
|
||||||
while (1) {
|
while (1) {
|
||||||
unsigned char input = getchar();
|
unsigned char input = getchar();
|
||||||
if (input == '\n') break;
|
if (input == '\n') break;
|
||||||
|
if (input >= 'a' && input <= 'z') input -= 32;
|
||||||
last_char = input;
|
last_char = input;
|
||||||
|
|
||||||
if (input < '0' || input > '9') continue;
|
if (input < '0' || input > '9') continue;
|
||||||
|
|
Loading…
Reference in a new issue