Cutting a Block

Time limit2sMemory limit64 MB

Problem

Carpenter Bill has a huge wooden block shaped like a rectangular parallelepiped (a box). The block is too large to fit through the door of Bill's house, so he decides to cut it into $n$ smaller blocks. To keep the pieces tidy, every small block must itself be a rectangular box, and all $n$ pieces must be equal.

Set up a coordinate system so that the edges of the block are parallel to the coordinate axes and one corner sits at the origin $(0, 0, 0)$; the opposite corner is then at $(x, y, z)$.

Cut the block into $n$ equal pieces using $n - 1$ evenly spaced planar cuts perpendicular to the $x$-axis. This produces $n$ identical slabs, each of size $\frac{x}{n} \times y \times z$. Report the slabs in order of increasing $x$-coordinate.

Input

A single line contains four integers $x$, $y$, $z$, and $n$ ($1 \le x, y, z, n \le 1000$) — the coordinates of the corner opposite the origin, and the number of pieces to cut.

Output

Print $n$ lines, one per slab, in order of increasing $x$-coordinate. Line $i$ (for $i = 0, 1, \dots, n - 1$) describes the slab whose opposite corners are $(x_1, y_1, z_1)$ and $(x_2, y_2, z_2)$, where

$$x_1 = \frac{i \cdot x}{n}, \quad y_1 = 0, \quad z_1 = 0, \quad x_2 = \frac{(i + 1) \cdot x}{n}, \quad y_2 = y, \quad z_2 = z.$$

Print the six coordinates on each line separated by single spaces, each rounded to exactly eight digits after the decimal point.

Hint