draw columns and rows of boxes based on user input