結果
| 問題 |
No.216 FAC
|
| コンテスト | |
| ユーザー |
ondy_candy
|
| 提出日時 | 2016-07-30 03:48:23 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 34 ms / 1,000 ms |
| コード長 | 362 bytes |
| コンパイル時間 | 111 ms |
| コンパイル使用メモリ | 12,672 KB |
| 実行使用メモリ | 10,880 KB |
| 最終ジャッジ日時 | 2024-11-06 20:16:26 |
| 合計ジャッジ時間 | 1,856 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 24 |
ソースコード
# -*- coding: utf-8 -*-
n = int(input())
a = [int(i) for i in input().split()]
b = [int(i) for i in input().split()]
score = {}
for i in range(n):
if b[i] in score:
score[b[i]] += a[i]
else:
score[b[i]] = a[i]
result = "NO"
if 0 in score:
if score[0] >= max([i for i in score.values()]):
result = "YES"
print(result)
ondy_candy