fork download
  1. wysokosc = int(input())
  2. szerokosc = int(input())
  3. for i in range(wysokosc):
  4. if i == 0 or i==wysokosc-1:
  5. print(szerokosc*"#")
  6. else:
  7. print("#",end="")
  8. print(" "*(szerokosc-2),end="")
  9. print("#")
  10.  
Success #stdin #stdout 0.07s 14212KB
stdin
5
6
stdout
######
#    #
#    #
#    #
######