Skip to main content
4 of 5
added 39 characters in body
user avatar
user avatar

#Python 3, 104 95 bytes ( feedback from @mbomb007 : -9 bytes)

def d(x,y):return'\n'.join(('|'+('-'*(x-2)if n<1or n==~-y else' '*(x-2))+'|')for n in range(y)) 

(my first code golf, appreciate feedback)

user59855