C Programming: Convert Character to Lowercase - A Common Error
The code reads a character from the input, converts it to lowercase by adding 32 to its ASCII value, and then prints the character 'A' to the output.
However, the converted character is not printed to the output. Instead, the character 'A' is printed, which is not related to the input character.
To print the converted character, the last line should be changed to:
putchar(A);
原文地址: https://www.cveoy.top/t/topic/oy8O 著作权归作者所有。请勿转载和采集!