Submission #587085

#TimeUsernameProblemLanguageResultExecution timeMemory
587085ygimCarnival (CEOI14_carnival)C++17
0 / 100
1 ms208 KiB
// P1_Carnival.cpp : This file contains the 'main' function. Program execution begins and ends there. // #include <iostream> #include <vector> #include <algorithm> #include <climits> #include <math.h> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0); int n; cin >> n; vector<int> costume(n, -1); int t = 1; for (int i = 0; i < n; i++) { if (costume[i] != -1) continue; costume[i] = t; for (int j = i + 1; j < n; j++) { if (costume[j] != -1) continue; cout << 2 << " " << i << " " << j << endl; int num; cin >> num; if (num == 1) costume[j] = t; } t++; } }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...