Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <iomanip>
- #include <cmath>
- #include <istream>
- #include <fstream>
- #include <string>
- #include <algorithm>
- #include <vector>
- #include <stdlib.h>
- #include <stdio.h>
- #include <string.h>
- using namespace std;
- int main() {
- string a;
- char b[100000];
- cin >> a;
- int m=a.length();
- strcpy(b, a.c_str());
- int n;
- cin >> n ;
- int skaicius;
- char raide;
- for(int i=0; i<n ; i++)
- {
- cin >> skaicius >> raide;
- b[skaicius-1]=raide;
- }
- string ats="";
- for(int i=0; i<m; i++)
- {
- ats+= b[i];
- }
- if(ats=="desmond")
- cout << "I love you, Desmond!" << endl << n << endl;
- else cout << "Goodbye, my love!" << endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement