#include <stdio.h>
int main(void) {
char linha[10001];
fgets(linha
, 10000, stdin
); // Lê a linha inteira. int pos = 0;
while (1) {
int y;
int p;
int ret
= sscanf(&linha
[pos
], "%d%n", &y
, &p
); // Retira um número da linha lida. pos += p;
if (ret == EOF) break;
}
}
I2luY2x1ZGUgPHN0ZGlvLmg+CgppbnQgbWFpbih2b2lkKSB7CiAgICBjaGFyIGxpbmhhWzEwMDAxXTsKICAgIGZnZXRzKGxpbmhhLCAxMDAwMCwgc3RkaW4pOyAvLyBMw6ogYSBsaW5oYSBpbnRlaXJhLgogICAgaW50IHBvcyA9IDA7CiAgICB3aGlsZSAoMSkgewogICAgICAgIGludCB5OwogICAgICAgIGludCBwOwogICAgICAgIGludCByZXQgPSBzc2NhbmYoJmxpbmhhW3Bvc10sICIlZCVuIiwgJnksICZwKTsgLy8gUmV0aXJhIHVtIG7Dum1lcm8gZGEgbGluaGEgbGlkYS4KICAgICAgICBwb3MgKz0gcDsKICAgICAgICBpZiAocmV0ID09IEVPRikgYnJlYWs7CiAgICAgICAgcHJpbnRmKCIlZCAiLCB5KTsKICAgIH0KICAgIHByaW50ZigiZmltIik7Cn0K