제출 #39762

#제출 시각아이디문제언어결과실행 시간메모리
39762krauch비교 (balkan11_cmp)C++14
0 / 100
932 ms82552 KiB
#include "cmp.h" #define forn(x, a, b) for (int x = a; x <= b; ++x) #define for1(x, a, b) for (int x = a; x >= b; --x) bool bit(int mask, int i) { return (mask >> i) & 1; } void remember(int n) { forn(i, 0, 11) { if (bit(n, i)) bit_set(i + 1); } } int compare(int b) { int cnt = 0; forn(i, 0, 11) { cnt += (bit_get(i + 1) << i); } if (cnt == b) return 0; }

컴파일 시 표준 에러 (stderr) 메시지

cmp.cpp: In function 'int compare(int)':
cmp.cpp:22:1: warning: control reaches end of non-void function [-Wreturn-type]
 }
 ^
#Verdict Execution timeMemoryGrader output
Fetching results...