結果
問題 |
No.3067 +10 Seconds Clock
|
ユーザー |
![]() |
提出日時 | 2025-04-16 00:12:31 |
言語 | PyPy3 (7.3.15) |
結果 |
RE
|
実行時間 | - |
コード長 | 381 bytes |
コンパイル時間 | 249 ms |
コンパイル使用メモリ | 82,392 KB |
実行使用メモリ | 67,040 KB |
最終ジャッジ日時 | 2025-04-16 00:13:48 |
合計ジャッジ時間 | 2,526 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | RE * 3 |
other | RE * 23 |
ソースコード
import sys from collections import defaultdict def main(): n = int(sys.stdin.readline()) a = list(map(int, sys.stdin.readline().split())) count_map = defaultdict(int) for num in a: count_map[num] += 1 ans = 0 for num in a: target = num ^ 1 ans += count_map.get(target, 0) print(ans // 2) if __name__ == "__main__": main()