#include <bits/stdc++.h> using namespace std; int main() { string str; while (getline(cin, str)) { while (str.find("occupation") != string::npos) { int index = str.find("occupation"); str.replace(index, 10, "OH-OH-OH-QQ-PEI-PEI-SHION"); } cout << str << endl; } return 0; } |
Double click to view unformatted code.