# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
1102684 |
2024-10-18T15:48:41 Z |
Choco |
Esej (COCI15_esej) |
C++14 |
|
7 ms |
1524 KB |
#include<bits/stdc++.h>
using namespace std;
#define Study ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL)
#define ll long long
#define pb push_back
#define ff first
#define ss second
#define fori for(ll i=1;i<=n;i++)
#define ins insert
void work(){
ll a,b;
cin>>a>>b;
ll fi=1,se=-1,th=-1,fo=-1;
string s="a";
if(a==1){
cout<<s;
return;
}
ll wordcnt=1;
while(wordcnt<a){
s+=" ";
string fi1="",se1="",th1="",fo1="";
if(fi>=0){
ll num=(int)'a';
fi1=char(fi+num);
}
if(se>=0){
ll num=(int)'a';
se1=char(se+num);
}
if(th>=0){
ll num=(int)'a';
th1=char(th+num);
}
if(fo>=0){
ll num=(int)'a';
fo1=char(fo+num);
}
string s1=fo1+th1+se1+fi1;
s+=s1;
fi++;
if(fi==26){
fi=0;
se++;
if(se>25){
se=0;
th++;
if(th>25){
th=0;
fo++;
}
}
}
wordcnt++;
}
cout<<s<<endl;
}
int main(){
Study;
ll t=1;
//cin>>t;
while(t--){
work();
}
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
340 KB |
Output is correct |
2 |
Correct |
1 ms |
340 KB |
Output is correct |
3 |
Incorrect |
1 ms |
340 KB |
Output isn't correct |
4 |
Incorrect |
1 ms |
340 KB |
Output isn't correct |
5 |
Correct |
1 ms |
340 KB |
Output is correct |
6 |
Incorrect |
2 ms |
760 KB |
Output isn't correct |
7 |
Incorrect |
1 ms |
596 KB |
Output isn't correct |
8 |
Correct |
6 ms |
1268 KB |
Output is correct |
9 |
Correct |
7 ms |
1524 KB |
Output is correct |
10 |
Incorrect |
1 ms |
340 KB |
Output isn't correct |