#include <iostream>
#include <cstdio>
#include <cstring>
#include <string>
using namespace std;
int main(){
long int i, count = 0;
char s[100000];
while(gets(s)){
for(i = 0; s[i]; i++){
if(s[i] == '"'){
count += 1;
if(count % 2 == 0){
printf("''");
}
else{
printf("``");
}
}
else
printf("%c", s[i]);
}
printf("\n");
}
return 0;
}
#include <cstdio>
#include <cstring>
#include <string>
using namespace std;
int main(){
long int i, count = 0;
char s[100000];
while(gets(s)){
for(i = 0; s[i]; i++){
if(s[i] == '"'){
count += 1;
if(count % 2 == 0){
printf("''");
}
else{
printf("``");
}
}
else
printf("%c", s[i]);
}
printf("\n");
}
return 0;
}
No comments:
Post a Comment