Submission #28433

# Submission time Handle Problem Language Result Execution time Memory
28433 2017-07-16T05:49:02 Z AcornCkiGuiziTeam(#1202, dotorya, cki86201, zigui) 1-Color Coloring (FXCUP2_coloring) C++14
0 / 1
0 ms 2024 KB
#include <stdio.h>  
#include <algorithm>  
#include <assert.h>
#include <bitset>
#include <cmath>  
#include <complex>  
#include <deque>  
#include <functional>  
#include <iostream>  
#include <limits.h>  
#include <map>  
#include <math.h>  
#include <queue>  
#include <set>  
#include <stdlib.h>  
#include <string.h>  
#include <string>  
#include <time.h>  
#include <unordered_map>  
#include <unordered_set>  
#include <vector>  

#pragma warning(disable:4996)  
#pragma comment(linker, "/STACK:1048576")  
using namespace std;

#define mp make_pair  
#define all(x) (x).begin(), (x).end()  
#define ldb ldouble

typedef long long ll;
typedef unsigned long long ull;
typedef double db;
typedef long double ldb;
typedef pair <int, int> pii;
typedef pair <ll, ll> pll;
typedef pair <ll, int> pli;
typedef pair <db, db> pdd;
typedef tuple <int, int, int> t3;

int IT_MAX = 1 << 17;
const ll MOD = 1000000007;
const int INF = 0x3f3f3f3f;
const ll LL_INF = 0x3f3f3f3f3f3f3f3f;
const db PI = acos(-1);
const db ERR = 1e-10;
#define szz(x) (int)(x).size()
#define rep(i, n) for(int i=0;i<(n);i++)

#include "coloring.h"
void ColoringSame(int N) {
	int st = 1, en = N, mi;
	while (st < en) {
		mi = (st + en) / 2;
		for (int i = st - 1; i <= en - 1; i++) Color((i == 0)?N:i);
		
		int t = GetColor(1);
		if (t == 0) en = mi;
		else st = mi + 1;
	}
	for (int i = st; i < st + N; i++) Color((i - 1) % N + 1);
}

Compilation message

coloring.cpp:23:0: warning: ignoring #pragma warning  [-Wunknown-pragmas]
 #pragma warning(disable:4996)  
 ^
coloring.cpp:24:0: warning: ignoring #pragma comment  [-Wunknown-pragmas]
 #pragma comment(linker, "/STACK:1048576")  
 ^
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 2024 KB Output isn't correct
2 Halted 0 ms 0 KB -