This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include<bits/stdc++.h>
using namespace std;
int a,b,c,d,e,i,j,ii,jj,zx,xc,tes,t;
string S[9],s;
char ch;
int main(){
ios_base::sync_with_stdio(false),cin.tie(0),cout.tie(0);
cin>>a;
cin>>S[1]>>S[2]>>S[3];
for(i=1; i<=3; i++) S[i]="0"+S[i];
cin>>tes;
cin>>s;s="0"+s;
for(t=1; t<=tes; t++){
cin>>c>>d>>ch;
for(i=c; i<=d; i++){
s[i]=ch;
}
for(i=1; i<=a; i++){
if(S[1][i]!=s[i]) break;
}
if(i==a+1){
cout<<"Yes\n";
}else{
cout<<"No\n";
}
}
return 0;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |