$n=<>; $_=join'|',(' 'x$n)x3; @_=($_)x length; map$_[$_]=~y/ |/-+/,$n,$n*2+1; print join$/,@_