#include int main() { char s[5000006]; scanf("%s", s); int i; char c = s[0]; printf("%c", c); for (i = 1; s[i] != '\0'; i++) { if (c == s[i]) continue; c = s[i]; printf("%c", c); } printf("\n"); return 0; }