結果

問題 No.11 カードマッチ
ユーザー dangodango
提出日時 2023-06-15 20:37:34
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 70 ms / 5,000 ms
コード長 186 bytes
コンパイル時間 699 ms
コンパイル使用メモリ 87,168 KB
実行使用メモリ 71,588 KB
最終ジャッジ日時 2023-09-05 23:29:04
合計ジャッジ時間 3,113 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 68 ms
71,136 KB
testcase_01 AC 70 ms
71,380 KB
testcase_02 AC 66 ms
71,248 KB
testcase_03 AC 68 ms
71,588 KB
testcase_04 AC 69 ms
71,368 KB
testcase_05 AC 68 ms
71,584 KB
testcase_06 AC 70 ms
71,296 KB
testcase_07 AC 66 ms
71,516 KB
testcase_08 AC 67 ms
71,276 KB
testcase_09 AC 64 ms
71,276 KB
testcase_10 AC 63 ms
71,348 KB
testcase_11 AC 64 ms
71,072 KB
testcase_12 AC 65 ms
71,204 KB
testcase_13 AC 66 ms
71,332 KB
testcase_14 AC 66 ms
71,164 KB
testcase_15 AC 68 ms
71,448 KB
testcase_16 AC 66 ms
71,272 KB
testcase_17 AC 66 ms
71,024 KB
testcase_18 AC 64 ms
71,384 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

W = int(input())
H = int(input())
N = int(input())
SK = sorted([list(map(int, input().split())) for _ in range(N)])
S, K = zip(*SK)
print(W * H - (W - len(set(S)))*(H - len(set(K))) - N)
0