This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef long double ld;
typedef double db;
typedef string str;
typedef pair<ll,ll> pl;
typedef vector<ll> vl;
typedef vector<vl> vvl;
#define mp make_pair
#define se second
#define pb push_back
#define pf push_front
#define nn <<"\n"
#define F0R(i,a) for(ll i=0;i<a;i++)
#define FOR(i,a,b) for(ll i=a;i<b;i++)
vector<int> coin_flips(vector<int> b, int c){
vector<int> flips(64,0);
F0R(i,64){
if(i != c){
if(b[i] == 1) flips[i] = i;
}else{
if(b[i] != 0) flips[i] = i;
}
}
return flips;
}
int find_coin(vector<int> b){
F0R(i,64){
if(b[i] == 1){
return i;
}
}
}
Compilation message (stderr)
coins.cpp: In function 'int find_coin(std::vector<int>)':
coins.cpp:36:1: warning: control reaches end of non-void function [-Wreturn-type]
36 | }
| ^
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |