結果

問題 No.784 「,(カンマ)」
ユーザー t.shibukit.shibuki
提出日時 2019-04-12 22:52:36
言語 PHP
(8.3.4)
結果
WA  
実行時間 -
コード長 300 bytes
コンパイル時間 515 ms
コンパイル使用メモリ 12,048 KB
実行使用メモリ 12,344 KB
最終ジャッジ日時 2023-10-13 08:49:56
合計ジャッジ時間 1,435 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 7 ms
12,256 KB
testcase_01 WA -
testcase_02 AC 7 ms
12,228 KB
testcase_03 AC 6 ms
12,212 KB
testcase_04 AC 7 ms
12,260 KB
testcase_05 AC 7 ms
12,192 KB
testcase_06 WA -
testcase_07 WA -
testcase_08 AC 7 ms
12,288 KB
testcase_09 WA -
testcase_10 WA -
testcase_11 AC 7 ms
12,164 KB
testcase_12 WA -
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php
$cnt=0;
$word=null;
$out=null;

fscanf(STDIN,"%d",$input);

$length=strlen($input);

for($i=0;$i<=$length-1;$i++){
    $word[]=substr($input,$i,1);
}

//print_r($word);

for($i=0;$i<=$length-1;$i++){
    if($i!=0 && $i%3==0){
        $out.=',';
    }
        $out.=$word[$i];
}

echo $out;

?>
0