結果
| 問題 | No.784 「,(カンマ)」 | 
| コンテスト | |
| ユーザー |  otsuri_114514 | 
| 提出日時 | 2019-03-12 15:23:32 | 
| 言語 | C (gcc 13.3.0) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 1 ms / 2,000 ms | 
| コード長 | 245 bytes | 
| コンパイル時間 | 136 ms | 
| コンパイル使用メモリ | 29,184 KB | 
| 実行使用メモリ | 6,944 KB | 
| 最終ジャッジ日時 | 2024-06-23 15:46:01 | 
| 合計ジャッジ時間 | 673 ms | 
| ジャッジサーバーID (参考情報) | judge2 / judge4 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 10 | 
ソースコード
#include <stdio.h>
#include <string.h>
int main(void){
  char s[110];
  scanf("%s",s);
  int n=strlen(s);
  printf("%c",s[0]);
  for(int i=1;i<n;i++){
    if(i%3==n%3) printf(",%c",s[i]);
    else printf("%c",s[i]);
  }
  puts("");
  return 0;
}
            
            
            
        