Submission #207556

# Submission time Handle Problem Language Result Execution time Memory
207556 2020-03-08T03:20:31 Z autumn_eel Broken Device (JOI17_broken_device) C++14
0 / 100
60 ms 3320 KB
#include "Annalib.h"
#include <bits/stdc++.h>
#define rep(i,n)for(int i=0;i<(n);i++)
using namespace std;
typedef long long ll;

bool b[160],d[160];

void Anna(int N,ll X,int K,int P[]){
	memset(b,0,sizeof(b));
	memset(d,0,sizeof(d));
	rep(i,K){
		b[P[i]]=1;
	}
	int t=59;
	int i=0;
	while(i<N-1){
		if(!b[i]&&!b[i+1]){
			d[i]=1;d[i+1]=(X>>t&1);
			if(t==0)break;
			t--;
			i+=2;
		}
		else i++;
	}
	//~ assert(t==0);
	rep(i,N)Set(i,d[i]);
}
#include "Brunolib.h"
#include <bits/stdc++.h>
#define rep(i,n)for(int i=0;i<(n);i++)
using namespace std;
typedef long long ll;

ll Bruno(int N,int A[]){
	ll ans=0;
	int i=0;
	while(i<N){
		if(A[i]==1){
			ans<<=1;
			ans+=A[i+1];
			i+=2;
		}
		else i++;
	}
	cerr<<"ans: "<<ans<<endl;
	return ans;
}
# Verdict Execution time Memory Grader output
1 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
2 Incorrect 54 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
3 Incorrect 56 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
4 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
5 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
6 Incorrect 56 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
7 Incorrect 60 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
8 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
9 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
10 Incorrect 57 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
11 Incorrect 56 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
12 Incorrect 54 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
13 Incorrect 56 ms 3320 KB Program terminated incorrectly, or you printed something to stdout
14 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
15 Incorrect 54 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
16 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
17 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
18 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
19 Incorrect 60 ms 3320 KB Program terminated incorrectly, or you printed something to stdout
20 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
21 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
22 Incorrect 54 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
23 Incorrect 59 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
24 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
25 Incorrect 57 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
26 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
27 Incorrect 60 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
28 Incorrect 57 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
29 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
30 Incorrect 54 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
31 Incorrect 56 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
32 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
33 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
34 Incorrect 57 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
35 Incorrect 60 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
36 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
37 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
38 Incorrect 56 ms 3320 KB Program terminated incorrectly, or you printed something to stdout
39 Incorrect 57 ms 3312 KB Program terminated incorrectly, or you printed something to stdout
40 Incorrect 55 ms 3312 KB Program terminated incorrectly, or you printed something to stdout