Submission #88624

# Submission time Handle Problem Language Result Execution time Memory
88624 2018-12-07T07:09:49 Z asifthegreat Esej (COCI15_esej) C++14
80 / 80
12 ms 2216 KB
#include <iostream>
#include <algorithm>
#include <string>
#include <bitset>
using namespace std;

int main()
{   
    string s;
    for(char a = 'a'; a <= 'm';a++)s.push_back(a);
    int a,b;
    cin >> a >> b;
    int cnt = 0;
    do{
        cout << s << " ";
        cnt++;
        if(cnt == b)break;
    }while(next_permutation(s.begin(),s.end()));
    return 0;
}
# Verdict Execution time Memory Grader output
1 Correct 2 ms 376 KB Output is correct
2 Correct 2 ms 620 KB Output is correct
3 Correct 2 ms 620 KB Output is correct
4 Correct 2 ms 620 KB Output is correct
5 Correct 3 ms 828 KB Output is correct
6 Correct 5 ms 1108 KB Output is correct
7 Correct 12 ms 2120 KB Output is correct
8 Correct 12 ms 2120 KB Output is correct
9 Correct 12 ms 2216 KB Output is correct
10 Correct 12 ms 2216 KB Output is correct