QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#132231 | #2928. Espresso! | heshamoomar | WA | 0ms | 3492kb | C++14 | 381b | 2023-07-29 05:06:41 | 2023-07-29 05:06:42 |
Judging History
answer
#include<iostream>
using namespace std;
int main(){
int n,s;
cin>>n>>s;
int total=0;
while (n--){
string st;cin>>st;
if(st.size()==1){
total+=st[0]-'0';
}
else{
total+=st[0]-'0';
total+=1;
}
}
(total%s)-1==-1?cout<<0:cout<<(total%s)-1;
return 0;
}//
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 0
Wrong Answer
time: 0ms
memory: 3492kb
input:
1 10 4L
output:
4
result:
wrong answer 1st lines differ - expected: '0', found: '4'