Product Triplet#1568

Product Triplet

1 second
64 megabytes
Very easy

You are given six integers: , , , , and . Find the number of triplets of integers (x, y, z) that satisfy the following four conditions:

Input

Each line contains six integers , , , , and . It is known that 1 \leq minx \leq maxx \leq 10^9, 1 \leq miny \leq maxy \leq 10^9, 1 \leq minz \leq maxz \leq 10^9.

Output

For each line of input, print on a separate line the number of triplets (x, y, z) that satisfy the given conditions.

Examples

Example 1

Loading
Loading