#include <stdio.h>
int main(void) {
char a[100], b[100];
int c, d;
while (4 == scanf("%[^:]:%[^:]:%d:%d", a
, b
, &c
, &d
)) { printf("%s#%s#%d#%d", a
, b
, c
, d
); }
return 0;
}
I2luY2x1ZGUgPHN0ZGlvLmg+CgppbnQgbWFpbih2b2lkKSB7CgljaGFyIGFbMTAwXSwgYlsxMDBdOwoJaW50IGMsIGQ7CndoaWxlICg0ID09IHNjYW5mKCIlW146XTolW146XTolZDolZCIsIGEsIGIsICZjLCAmZCkpIHsKICAgIHByaW50ZigiJXMjJXMjJWQjJWQiLCBhLCBiLCBjLCBkKTsKfQoJcmV0dXJuIDA7Cn0K