Mock CCC '19 Contest 2 S1 - Tudor's Double Doors

View as PDF

Submit solution

Points: 3 (partial)
Time limit: 1.0s
Memory limit: 1G

Problem type

Tudor, having finally had his fill of tea, now needs to think about keeping his goats safe.

Tudor has obtained a large rectangular door that is X metres long, Y metres high, and 1 metre thick. He intends on using this door to gate access to his goats.

There's only one problem - having just one door is aesthetically unpleasing to Tudor.

Therefore, he intends on taking the door and cutting it in half to make a set of double doors that he can use to gate access to his goats.

After cutting the door in half, what is the volume of one of the doors?


1 \le X, Y \le 10^9

In tests worth 14 marks, \max(X, Y) \le 10.

Input Specification

The input will consist of two positive space separated integers, X and Y.

Output Specification

Output, on a single line, the volume of one of the doors. The volume must be printed with exactly one digit after the decimal point.

Sample Input

2 2

Sample Output



  • 0
    HusseinK  commented on March 10, 2021, 2:55 p.m.

    Small hint if you are having trouble with batch #2: Your data type has to be able to store AT LEAST 64-bits, so you have to use a long variable type.

    • 0
      QiQi  commented on Nov. 24, 2021, 1:05 a.m. edit 3

      Thanks! I was having trouble with batch 2! Try 1000000000 and 1000000000 if you don't see why.

  • 1
    JJ_G4M3R  commented on Feb. 18, 2019, 1:34 a.m. edited

    Is Batch #2 even solvable?

    Java's String.format some how doesn't work... Figured out how to solve it without using String.format

    • 0
      andrewfeng123  commented on Feb. 18, 2019, 7:50 p.m.

      It's tricky tho

    • 2
      echofox  commented on Feb. 18, 2019, 1:46 a.m.