結果
問題 | No.216 FAC |
ユーザー |
![]() |
提出日時 | 2015-05-26 22:39:03 |
言語 | C++11 (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 1,000 ms |
コード長 | 393 bytes |
コンパイル時間 | 484 ms |
コンパイル使用メモリ | 62,100 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-10-15 00:32:34 |
合計ジャッジ時間 | 1,318 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 24 |
ソースコード
#include<iostream>#include<vector>#include<algorithm>using namespace std;int main(){int n;cin>>n;vector<int> score(n);for(int i=0;i<n;i++) cin>>score[i];vector<int> man(101);fill(man.begin(),man.end(),0);for(int i=0;i<n;i++){int b;cin>>b;man[b]+=score[i];}if(max_element(man.begin(),man.end()) == man.begin()) cout<<"YES"<<endl;else cout<<"NO"<<endl;return 0;}