結果
問題 |
No.216 FAC
|
ユーザー |
|
提出日時 | 2017-05-17 15:30:26 |
言語 | D (dmd 2.109.1) |
結果 |
AC
|
実行時間 | 2 ms / 1,000 ms |
コード長 | 329 bytes |
コンパイル時間 | 841 ms |
コンパイル使用メモリ | 143,096 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-06-12 19:18:27 |
合計ジャッジ時間 | 1,675 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 24 |
ソースコード
import std.algorithm, std.conv, std.range, std.stdio, std.string; void main() { auto n = readln.chomp.to!size_t; auto ai = readln.split.to!(int[]); auto bi = readln.split.to!(int[]); auto si = new int[](101); foreach (a, b; lockstep(ai, bi)) si[b] += a; writeln(si[0] >= si[1..$].maxElement ? "YES" : "NO"); }