Created
July 9, 2019 06:40
-
-
Save hamayanhamayan/c7731e5607f6334879a5ec2784d6da51 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<bits/stdc++.h> | |
#define rep(i,a,b) for(int i=a;i<b;i++) | |
#define rrep(i,a,b) for(int i=a;i>=b;i--) | |
#define fore(i,a) for(auto &i:a) | |
#define all(x) (x).begin(),(x).end() | |
//#pragma GCC optimize ("-O3") | |
using namespace std; void _main(); int main() { cin.tie(0); ios::sync_with_stdio(false); _main(); } | |
typedef long long ll; const int inf = INT_MAX / 2; const ll infl = 1LL << 60; | |
template<class T>bool chmax(T &a, const T &b) { if (a<b) { a = b; return 1; } return 0; } | |
template<class T>bool chmin(T &a, const T &b) { if (b<a) { a = b; return 1; } return 0; } | |
//--------------------------------------------------------------------------------------------------- | |
/*--------------------------------------------------------------------------------------------------- | |
∧_∧ | |
∧_∧ (´<_` ) Welcome to My Coding Space! | |
( ´_ゝ`) / ⌒i @hamayanhamayan | |
/ \ | | | |
/ / ̄ ̄ ̄ ̄/ | | |
__(__ニつ/ _/ .| .|____ | |
\/____/ (u ⊃ | |
---------------------------------------------------------------------------------------------------*/ | |
//--------------------------------------------------------------------------------------------------- | |
void _main() { | |
string s; | |
rep(i, 0, 19) { | |
getline(cin, s); | |
int idx = 0; | |
while (idx + 2 < s.size()) { | |
if (s[idx] == '%' and s[idx + 2] == '%') { | |
s = s.substr(0, idx) + s.substr(idx + 3); | |
} | |
else idx++; | |
} | |
cout << s << endl; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment