# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
383154 | Iwanttobreakfree | Kartomat (COCI17_kartomat) | C++98 | 2 ms | 364 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <iostream>
#include <vector>
#include <string>
using namespace std;
int main(){
int n;
string str[101];
string g="***ABCDEFGHIJKLMNOPQRSTUVWXYZ***";
string st;
cin>>n;
for(int i=0;i<n;i++) cin>>str[i];
cin>>st;
int l=st.length();
vector<bool> v(32,false);
for(int i=0;i<n;i++){
string sub=str[i].substr(0,l);
if(sub==st) v[g.find(str[i][l])]=true;
}
for(int i=0;i<32;i+=8){
for(int j=0;j<8;j++){
if(v[i+j])cout<<g[i+j];
else cout<<'*';
}
cout<<'\n';
}
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |