Submission #1034180

#TimeUsernameProblemLanguageResultExecution timeMemory
1034180vjudge1cmp (balkan11_cmp)C++17
0 / 100
889 ms82556 KiB
#include "cmp.h" #include <bits/stdc++.h> using namespace std; void remember(int n) { for (int i = 0; i <= 11; i++) { if ((n >> i) & 1) bit_set(i+1); } } int compare(int n) { for (int i = 11; i >= 0; i--) { int x = bit_get(i+1); int y = (n >> i) & 1; if (x > y) return -1; else if (x < y) return 1; } return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...