You are incorrectly calculating the number of spaces to put in your top and bottom number strings, you are incorrectly calculating the length of the bottom dashes string, and you are adding only 2 spaces in between problems instead of 4.
The width of each problem should be the length of the largest number plus 1 for a space and plus 1 for the operator (so max(len()) + 2). You should be able to recalculate the spacing from there.