Submission #71738

# Submission time Handle Problem Language Result Execution time Memory
71738 2018-08-25T13:54:51 Z 퍼솔 가즈아ㅏㅏㅏ(#2222, 16silver) Angelic Hourglass (FXCUP3_hourglass) C++14
0 / 100
3 ms 628 KB
#include <cstdio>
int a[20]={0,0,0,1,-1,1,2,4,2,3,2,3,4,3,4,3};
int main(){
    int N;
    scanf("%d",&N);
    if(N<16) printf("%d",a[N]);
    else{
        if(N%5==0) return N/5;
        else if(N%5==1 || N%5==3) return N/5+1;
        else return N/5+2;
    }
}

Compilation message

hourglass.cpp: In function 'int main()':
hourglass.cpp:5:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
     scanf("%d",&N);
     ~~~~~^~~~~~~~~
# Verdict Execution time Memory Grader output
1 Runtime error 2 ms 508 KB Execution failed because the return code was nonzero
2 Runtime error 2 ms 508 KB Execution failed because the return code was nonzero
3 Runtime error 1 ms 356 KB Execution failed because the return code was nonzero
4 Correct 2 ms 248 KB Output is correct
5 Runtime error 2 ms 432 KB Execution failed because the return code was nonzero
# Verdict Execution time Memory Grader output
1 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
2 Correct 2 ms 508 KB Output is correct
3 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
4 Correct 2 ms 576 KB Output is correct
5 Correct 3 ms 508 KB Output is correct
6 Runtime error 3 ms 628 KB Execution failed because the return code was nonzero
7 Correct 2 ms 592 KB Output is correct
8 Correct 2 ms 508 KB Output is correct
9 Runtime error 2 ms 592 KB Execution failed because the return code was nonzero
10 Correct 2 ms 508 KB Output is correct
11 Correct 2 ms 592 KB Output is correct
12 Correct 2 ms 508 KB Output is correct
13 Correct 2 ms 508 KB Output is correct
14 Correct 2 ms 508 KB Output is correct
15 Correct 3 ms 592 KB Output is correct
16 Correct 2 ms 544 KB Output is correct
17 Correct 3 ms 576 KB Output is correct
18 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
# Verdict Execution time Memory Grader output
1 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
2 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
3 Incorrect 2 ms 628 KB Output isn't correct
4 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
5 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
6 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
7 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
8 Runtime error 1 ms 628 KB Execution failed because the return code was nonzero
9 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
10 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
11 Runtime error 2 ms 628 KB Execution failed because the return code was nonzero
12 Runtime error 1 ms 628 KB Execution failed because the return code was nonzero