LearnPy Hub
← Arena
EasyRating 900

Undo the Pairs

Bob wrote every pair of neighbouring letters of a word a (length ≥ 2) one after another to make b. Given b, print a.

Input

One string b.

Output

One string a.

Sample 1

Input
abbaac
Output
abac

Sample 2

Input
ac
Output
ac
solution.py
Output appears here
Undo the Pairs · Python Arena problem · LearnPy Hub