結果

問題 No.2692 How Many Times Reached?
ユーザー Nichi10p
提出日時 2024-03-22 21:35:48
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 275 bytes
コンパイル時間 282 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 10,880 KB
最終ジャッジ日時 2024-09-30 11:02:26
合計ジャッジ時間 2,462 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 40 WA * 3
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
S = tuple(tuple(input()) for _ in range(N))

cnt = 0
for _ in range(2):
  cnt += sum(row.count('A') == N-1 for row in S)
  S = tuple(zip(*S))
cnt += sum(S[i][i] == 'A' for i in range(N)) == N-1
cnt += sum(S[i][~i] == 'A' for i in range(N)) == N-1

print(cnt)
0