Alternative Architecture
시간 제한1초메모리 제한1024 MB
a×b 직사각형의 네 모서리 판이 정수 격자 못 위에 오도록 놓는 서로 다른 방향의 수를 센다.
문제
In his free time, Thomas greatly enjoys working on the extensive Lego project that he has built in his attic, adding house after house to his miniature city. However, he has become a bit bored with the completely rectangular layout that is enforced by the little studs of the huge base plate that his city is built on.
After an exchange with some other Lego creators he came across a technique that will allow him to place his buildings at different angles. Each building rests on a rectangular ground plate, to the underside of which he attaches four round -plates in the corners. These -plates are then placed on four studs of the base plate, like in Figure A.1.

Figure A.1: Placing a plate diagonally.
If the ground plate of the building is studs, what is the number of orientations it can be placed in using this technique, so that all the corner plates exactly fit on studs of the base plate?

Figure A.2: Illustration of the first sample case. There are many ways of placing a plate, but only distinct orientations.
입력
The input consists of:
- One line with two integers and (), the dimensions of the ground plate the building is resting on.
출력
Output one integer, the number of different orientations the ground plate can be placed in.