n=gets.to_i-2 s=gets.chop t=s.chars.map{|c|c*(n+2)}*"" puts t,[s.chars.map{|c|c+" "*n+c}*""]*n,t