AtCoder Grand Contest 004
A
Divide a Cuboid
AtCoder
⌀ 558
原题
←B →
翻译中…

Problem Statement

翻译中…

We have a rectangular parallelepiped of size $A×B×C$, built with blocks of size $1×1×1$. Snuke will paint each of the $A×B×C$ blocks either red or blue, so that:

翻译中…
  • There is at least one red block and at least one blue block.
  • The union of all red blocks forms a rectangular parallelepiped.
  • The union of all blue blocks forms a rectangular parallelepiped.
翻译中…

Snuke wants to minimize the difference between the number of red blocks and the number of blue blocks. Find the minimum possible difference.

翻译中…

Constraints

翻译中…
  • $2≤A,B,C≤10^9$
翻译中…

Input

翻译中…

The input is given from Standard Input in the following format:

翻译中…

A B C

翻译中…

Output

翻译中…

Print the minimum possible difference between the number of red blocks and the number of blue blocks.

翻译中…

样例

Input #1
3 3 3
Output #1
9
For example, Snuke can paint the blocks as shown in the diagram below. There are $9$ red blocks and $18$ blue blocks, thus the difference is $9$. ![image](https://atcoder.jp/img/agc/004/gatbantar/A_1.png)
Input #2
2 2 4
Output #2
0
For example, Snuke can paint the blocks as shown in the diagram below. There are $8$ red blocks and $8$ blue blocks, thus the difference is $0$. ![image](https://atcoder.jp/img/agc/004/gatbantar/A_2.png)
Input #3
5 3 5
Output #3
15
For example, Snuke can paint the blocks as shown in the diagram below. There are $45$ red blocks and $30$ blue blocks, thus the difference is $9$. ![image](https://atcoder.jp/img/agc/004/gatbantar/A_3.png)
题目信息
题号
agc004_a
时间限制
2 s
内存限制
256 MB

题面与样例版权归 AtCoder 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。