f 0="" f 1="()" f i="("++f d++")"++f m where(d,m)=divMod i 2 g i="("++f i++")" m@main=readLn>>=putStrLn.g>>m