Submission #738504

#TimeUsernameProblemLanguageResultExecution timeMemory
738504mzvEsej (COCI15_esej)C++17
80 / 80
14 ms908 KiB
#include <bits/stdc++.h> #define ccd ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0); #define ll long long #define endl '\n' using namespace std; /* ------------------------ hi lol ------------------------ */ int n,m; char words[6]; int main() { ccd cin >> n >> m; for (int i=1;i<=5;i++) { words[i]='a'; } while (m--) { for (int i=1;i<=5;i++) { cout << words[i]; } if (m>0) cout << " "; for (int i=5;i>=1;i--) { if (words[i]>='z') { words[i]='a'; continue; } words[i]++; break; } } }
#Verdict Execution timeMemoryGrader output
Fetching results...