It is time to repaint the apartment again. Bajtazar is not fond of painting, but he noticed that the paint cans and brushes sparked lively interest among his children. So he handed out the brushes and asked the children to paint one of the walls. Each child painted a rectangular region whose sides are parallel or perpendicular to the floor.
Unfortunately, the paint Bajtazar bought is not of the best quality, so the only parts of the wall that look good now are those that were skipped (left unpainted) by at most one child. What is the total area of those parts?
The first line contains an integer n (2≤n≤500000), the number of Bajtazar's children.
Each of the next n lines describes the region painted by one child. The i-th of these lines contains four integers x1, y1, x2, y2 (0≤x1<x2≤109, 0≤y1<y2≤109). They mean that the i-th child painted the rectangle whose lower-left corner is at (x1,y1) and upper-right corner is at (x2,y2), with sides parallel to the coordinate axes.
Print a single integer: the area of the part of the wall that needs no further painting, that is, the part painted by at least n−1 children.

The regions painted in the darker and the darkest colors in the figure are included in the result.