fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int i;
  5. char s[100];
  6.  
  7. scanf("%s", s);
  8. printf("%s\n -> ", s);
  9.  
  10. // 1文字ずつ処理して表示
  11. for(i = 0; s[i] != '\0'; i++) {
  12. if(s[i] == 1)
  13. printf("I");
  14. else
  15. printf("%c", s[i]);
  16. }
  17.  
  18. printf("\n");
  19.  
  20. return 0;
  21. }
  22.  
Success #stdin #stdout 0.01s 5288KB
stdin
1NFORMATION
stdout
1NFORMATION
  -> 1NFORMATION