結果

問題 No.712 赤旗
ユーザー ayaaya
提出日時 2019-08-06 10:31:13
言語 PHP
(8.3.4)
結果
AC  
実行時間 19 ms / 2,000 ms
コード長 237 bytes
コンパイル時間 58 ms
コンパイル使用メモリ 18,620 KB
実行使用メモリ 19,120 KB
最終ジャッジ日時 2023-09-25 17:38:15
合計ジャッジ時間 1,047 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
18,876 KB
testcase_01 AC 19 ms
18,980 KB
testcase_02 AC 18 ms
19,004 KB
testcase_03 AC 17 ms
19,120 KB
testcase_04 AC 17 ms
18,992 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php
$matrix=explode(" ",trim(fgets(STDIN)));
$cntRed=0;
$cntWhite=$matrix[0]*$matrix[1];
for($i=0;$i<$matrix[0];$i++){
  $input=trim(fgets(STDIN));
  $cntRed+=preg_match_all("/R/",$input);
}
$cntWhite=$cntWhite-$cntRed;
echo $cntWhite;
0