a=input() l,c,r=b=f='/|\\' while a!=b: print(a);b=a for x in[(f,'_'),(l+c,l+l),(c+r,r+r),('_',f)]:a=a.replace(*x)