# constant for scaling figure size SIZE = 4 # draw a horizontal line def line(): print "#" + "=" * (4 * SIZE) + "#" # draw the top half of the mirror def top_half(): for line in range(1, SIZE + 1): print "|" + \ " " * (-2 * line + (2 * SIZE)) + \ "<>" + \ "." * (4 * line - 4) + \ "<>" + \ " " * (-2 * line + (2*SIZE)) + \ "|" # draw the bottom half of the mirror def bottom_half(): for line in : print "|" + \ " " * (-2 * line + (2 * SIZE)) + \ "<>" + \ "." * (4 * line - 4) + \ "<>" + \ " " * (-2 * line + (2*SIZE)) + \ "|" # main "method" line() top_half() bottom_half() line()