답안 #20193

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
20193 2016-03-04T16:17:28 Z kipa00 팩토리얼 세제곱들의 합 (YDX14_fact) C++
0 / 1
2 ms 0 KB
#include <cstdio>

int main() {
    int n, k;
    scanf("%d%d", &n, &k);
    printf("%c\n", "124141262812165"[((n>=4)?4:n)+k*5-5]);
    return 0;
}

Compilation message

fact.cpp: In function 'int main()':
fact.cpp:5:26: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
     scanf("%d%d", &n, &k);
                          ^
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 0 KB answer is '4'
2 Correct 1 ms 0 KB answer is '2'
3 Correct 1 ms 0 KB answer is '2'
4 Correct 1 ms 0 KB answer is '2'
5 Correct 1 ms 0 KB answer is '2'
6 Correct 1 ms 0 KB answer is '4'
7 Correct 1 ms 0 KB answer is '6'
8 Correct 1 ms 0 KB answer is '1'
9 Correct 1 ms 0 KB answer is '2'
10 Correct 2 ms 0 KB answer is '6'
11 Correct 2 ms 0 KB answer is '4'
12 Correct 2 ms 0 KB answer is '5'
13 Incorrect 1 ms 0 KB % is not a valid integer
14 Incorrect 2 ms 0 KB c is not a valid integer
15 Incorrect 2 ms 0 KB Unexpected end of file - token expected
16 Incorrect 2 ms 0 KB is not a valid integer
17 Incorrect 2 ms 0 KB is not a valid integer
18 Incorrect 1 ms 0 KB is not a valid integer
19 Incorrect 2 ms 0 KB is not a valid integer
20 Incorrect 1 ms 0 KB is not a valid integer
21 Incorrect 1 ms 0 KB is not a valid integer
22 Incorrect 1 ms 0 KB is not a valid integer
23 Incorrect 1 ms 0 KB is not a valid integer
24 Incorrect 1 ms 0 KB is not a valid integer
25 Incorrect 1 ms 0 KB is not a valid integer
26 Incorrect 1 ms 0 KB is not a valid integer
27 Incorrect 1 ms 0 KB is not a valid integer
28 Incorrect 1 ms 0 KB is not a valid integer
29 Incorrect 1 ms 0 KB is not a valid integer
30 Incorrect 1 ms 0 KB is not a valid integer
31 Correct 1 ms 0 KB answer is '4'
32 Correct 2 ms 0 KB answer is '4'
33 Correct 1 ms 0 KB answer is '4'
34 Correct 1 ms 0 KB answer is '4'
35 Correct 1 ms 0 KB answer is '4'
36 Correct 2 ms 0 KB answer is '4'
37 Correct 2 ms 0 KB answer is '4'
38 Correct 1 ms 0 KB answer is '4'
39 Correct 1 ms 0 KB answer is '4'
40 Correct 1 ms 0 KB answer is '8'
41 Correct 1 ms 0 KB answer is '8'
42 Correct 1 ms 0 KB answer is '8'
43 Correct 1 ms 0 KB answer is '8'
44 Correct 1 ms 0 KB answer is '8'
45 Correct 2 ms 0 KB answer is '8'
46 Correct 1 ms 0 KB answer is '8'
47 Correct 1 ms 0 KB answer is '8'
48 Correct 2 ms 0 KB answer is '8'
49 Correct 1 ms 0 KB answer is '5'
50 Correct 1 ms 0 KB answer is '5'
51 Correct 1 ms 0 KB answer is '5'
52 Correct 2 ms 0 KB answer is '5'
53 Correct 1 ms 0 KB answer is '5'
54 Correct 2 ms 0 KB answer is '5'
55 Correct 1 ms 0 KB answer is '5'
56 Correct 2 ms 0 KB answer is '5'
57 Correct 1 ms 0 KB answer is '5'