#line 1 "main.cpp" #include #include #include #include #include using namespace std; void solve() { string s; cin >> s; char prev = '$'; for (auto c : s) { if (c != prev) cout << c; prev = c; } cout << "\n"; } int main() { cin.tie(nullptr); ios::sync_with_stdio(false); solve(); return 0; }