# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
673571 | 2022-12-21T07:08:46 Z | WebbWayne | Igra (COCI17_igra) | C++17 | 1000 ms | 212 KB |
#include <iostream> #include <bits/stdc++.h> using namespace std; #define rep(i, a, b) for(int i = a; i < b; i++) bool checker(string temp, string word) { rep(i, 0, temp.size()) { if(temp[i] == word[i]) return true; } return false; } int main() { int n; cin>>n; vector<char> letter(n); rep(i, 0, n) { cin>>letter[i]; } string word; cin>>word; string temp = word; sort(temp.begin(), temp.end()); do { next_permutation(temp.begin(), temp.end()); }while(checker(temp, word)); cout<<temp<<endl; return 0; }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Execution timed out | 1098 ms | 212 KB | Time limit exceeded |
2 | Incorrect | 21 ms | 212 KB | Output isn't correct |
3 | Incorrect | 127 ms | 212 KB | Output isn't correct |
4 | Execution timed out | 1099 ms | 212 KB | Time limit exceeded |
5 | Execution timed out | 1091 ms | 212 KB | Time limit exceeded |
6 | Execution timed out | 1096 ms | 212 KB | Time limit exceeded |
7 | Execution timed out | 1096 ms | 212 KB | Time limit exceeded |
8 | Execution timed out | 1083 ms | 212 KB | Time limit exceeded |
9 | Execution timed out | 1093 ms | 212 KB | Time limit exceeded |
10 | Execution timed out | 1095 ms | 212 KB | Time limit exceeded |