Submission #26174

# Submission time Handle Problem Language Result Execution time Memory
26174 2017-06-28T08:14:17 Z 서규호(#1097) None (JOI16_snowy) C++14
0 / 100
9 ms 4172 KB
#include "Anyalib.h"
#include <bits/stdc++.h>

#define pb push_back

using namespace std;

static int getL;

static int N;
static int ans[502];
static vector<int> edge[502];

void InitAnya(int n , int A[] , int B[]) {
	N = n;
	for(int i=0; i<N-1; i++){
		edge[A[i]].pb(B[i]);
		edge[B[i]].pb(A[i]);
	}
}

void Anya(int C[]) {
	for(int i=0; i<N-1; i++){
		ans[i+1] = ans[i]+C[i];
	}
	int cnt = 0;
	for(int i=10; i<N; i++){
		int x = ans[i];
		for(int j=1; j<=10; j++){
			Save(cnt++,x%2);
			x /= 2;
		}
	}
	for(int i=0; i<N-1; i++){
		Save(cnt++,C[i]);
	}
}
#include "Borislib.h"
#include <bits/stdc++.h>

#define pb push_back

using namespace std;

static int N,ans;
static vector<int> edge[502];

void InitBoris(int n , int A[] , int B[]) {
	N = n;
	for(int i=0; i<N-1; i++){
		edge[A[i]].pb(B[i]);
		edge[B[i]].pb(A[i]);
	}
}

int Boris(int city) {
	int t,tmp;
	tmp = ((N-1)/10)*10;
	ans = 0;
	if(city >= 10){
		t = (city/10)*10-10;
		int two = 1;
		for(int i=t; i<t+10; i++){
			ans += (two*Ask(i));
		}
	}
	for(int i=(city/10)*10; i<city; i++) ans += Ask(tmp+i);

	return ans;
}

Compilation message

Anya.cpp:8:12: warning: 'getL' defined but not used [-Wunused-variable]
 static int getL;
            ^
# Verdict Execution time Memory Grader output
1 Correct 0 ms 4172 KB Output is correct
2 Incorrect 0 ms 4172 KB Wrong Answer [7]
3 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 9 ms 4172 KB Wrong Answer [7]
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 4172 KB Wrong Answer [1]
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 4172 KB Wrong Answer [1]
2 Halted 0 ms 0 KB -