program t;var i:Integer;s: string;p: string;begin Read(p);s := '';for i := Length(p) downto 1 do if p[i]=')' then s:=s+'(' else if p[i]='(' then s:=s+')' else if p[i]='b' then s:=s+'d' else s:=s+p[i];writeln('happy '+s+' new '+p+' year!');end.