Submission #1002886

#TimeUsernameProblemLanguageResultExecution timeMemory
1002886JuanMalnaRISC (COI21_malnarisc)C++17
76.41 / 100
2 ms508 KiB
#include<bits/stdc++.h> using namespace std; #define pb push_back #define pii pair<int,int> void print(int a, int b){ cout << "CMPSWP "; cout << "R" << a << " "; cout << "R" << b << " "; } int main(){ int n; cin >> n; int magic=n; if(n<=20) magic=n; cout << magic << '\n'; for(int i=1; i<=magic; i++){ for(int j=1+(i%2); j<n; j+=2){ print(j,j+1); } cout << '\n'; } }
#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...
#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...