面试题答案
一键面试#include <stdio.h>
#include <ctype.h>
#include <string.h>
void convertToUpperCase(char *str) {
for (int i = 0; i < strlen(str); i++) {
str[i] = toupper(str[i]);
}
}
int main() {
char str[] = "Hello, World!";
convertToUpperCase(str);
printf("%s\n", str);
return 0;
}