QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#319041 | #7728. Ramen | Albert711 | WA | 1ms | 3812kb | C++20 | 620b | 2024-02-01 16:50:42 | 2024-02-01 16:50:43 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef double db;
const int N = 2005 + 5;
const int mod = 1e9+7;
void solve() {
int n;
cin>>n;
vector<ll> a(n+1);
for(int i=1;i<=n;i++) cin>>a[i];
ll cnt=a[1];
for(int i=2;i<=n;i++){
if(cnt<=0){
cout<<"No\n";
return;
}
}
cout<<"Yes\n";
}
signed main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
cout.tie(nullptr);
// cout<<fixed<<setprecision(7);
int T = 1;
// cin >> T;
while (T--) solve();
return 0;
}
详细
Test #1:
score: 100
Accepted
time: 1ms
memory: 3812kb
input:
3 1 2 -5
output:
Yes
result:
ok YES
Test #2:
score: -100
Wrong Answer
time: 1ms
memory: 3488kb
input:
5 2 -5 2 3 1
output:
Yes
result:
wrong answer expected NO, found YES [1st token]