# CSE 142, Summer 2008 (Kim Todd) # This program draws lines and boxes of stars. # Draws a box of stars with the given width/height, # and using an optional outline character (default of "*"). def box(width, height, outline="*"): print width * outline for i in range(height - 2): print outline + (width - 2) * " " + outline print width * outline # main print 13 * "*" print 7 * "*" print 35 * "*" print box(10, 3) box(5, 4) box(7, 5, "#") box(20, 4, "$")