제출 #311779

#제출 시각아이디문제언어결과실행 시간메모리
311779zakaFMemory (IOI10_memory)C++14
100 / 100
2 ms484 KiB
#include <iostream>
#include <cstdlib>
#include <algorithm>
#include <cmath>
#include <vector>
#include <set>
#include <map>
#include <unordered_set>
#include <unordered_map>
#include <cstring>

using namespace std;
using ll = long long;
using ld = long double;
using uint = unsigned int;
using ull = unsigned long long;
#include "grader.h"
#include "memory.h"
#define pb push_back
#define mp make_pair
#define all(x) (x).begin(),(x).end()
#define rall(x) (x).rbegin(),(x).rend()
#define fi first
#define se second
#ifdef LOCAL
	#include </home/linux/debug.h>
	#define dbg(...) cout << "LINE(" << __LINE__ << ") -> [" << #__VA_ARGS__ << "]: [", _print(__VA_ARGS__)
#else
	#define dbg(...)
#endif

void play() 
{
	int where[100],p = -1;
	memset(where,-1,sizeof(where));
	for(int i  = 1;i<=50;i++)
	{
		int c = (int)(faceup(i)-'A');
		if(p != -1)
			p = -1;
		else
			p = c;
		if(where[c]!=-1)
		{
			if(p == -1)
				faceup(i);
			faceup(where[c]);
			p = -1;
		}
		else
			where[c] = i;
	}
}
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...