Wow! This problem is kind of tricky. If you're ready to put your thinking cap on, brace yourself and good luck! Otherwise, you can skip it for now and return any time later.
A school has decided to create three new math groups and equip three classrooms for them with new desks. Your task is to calculate the minimum number of desks to be purchased. To do so, you'll need the following information:
- The number of students in each of the three groups is known: your program will receive three non-negative integers as the input. It is possible that one or more of them will be zero, so you should take it into account.
- Each group will sit in its own classroom. It means that you should calculate the number of desks for each classroom separately, and only then add them up!
- At most two students may sit at any desk. You are expected to output the minimum number of desks to buy, so there should be as many as possible desks taken by two students rather than one.
Most probably, you'll need operations // and % in your program!