Two dimensional arrays
Three rectangles are painted on the white sheet of paper so that their sides lie on the grid lines and the vertices have integer coordinates. Find the total number of painted cells.
Three lines contain four integers - the coordinates of two opposite vertices of each rectangle (the coordinates do not exceed 100 by absolute value).
Print the number of painted cells.
2 2 5 6 3 3 7 1 6 4 4 7