import std.stdio;void main(){for(int c,d;~(c=getchar());putchar(c+=d<1))d=c%7?++d%51-c%2*51:0;}