結果
| 問題 | No.784 「,(カンマ)」 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-04-12 22:50:43 |
| 言語 | PHP (8.5.4) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 296 bytes |
| 記録 | |
| コンパイル時間 | 2,733 ms |
| コンパイル使用メモリ | 36,276 KB |
| 実行使用メモリ | 37,032 KB |
| 最終ジャッジ日時 | 2026-04-04 17:45:22 |
| 合計ジャッジ時間 | 3,694 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 3 |
| other | AC * 2 WA * 8 |
コンパイルメッセージ
No syntax errors detected in Main.php
ソースコード
<?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=$length-1;$i>=0;$i--){
$out.=$word[$i];
if($i!=0 && $i%3==0){
$out.=',';
}
}
echo $out;
?>