## Wesley's Anger Contest 3 Problem 2 - Eat, Sleep, Code, Repeat

View as PDF

Points: 5 (partial)
Time limit: 1.0s
Memory limit: 256M

Author:
Problem type
Allowed languages
Ada, Assembly, Awk, Brain****, C, C#, C++, COBOL, CommonLisp, D, Dart, F#, Forth, Fortran, Go, Groovy, Haskell, Intercal, Java, JS, Kotlin, Lisp, Lua, Nim, ObjC, OCaml, Octave, Pascal, Perl, PHP, Pike, Prolog, Python, Racket, Ruby, Rust, Scala, Scheme, Sed, Swift, TCL, Text, Turing, VB, Zig

As an avid programmer, Carson likes to live by the following phrase:

"Eat, sleep, code, repeat."

However, sometimes he does one task more than the others. When doing a self-assessment on his efficiency during a specific day, he has developed the following formula to measure his productivity.

The formula is defined as , where , , and are the number of hours in the day used on eating, sleeping, and coding respectively. The sum of these three activities must be equal to the number of hours he has during that day. Since Carson does not like to switch tasks in the middle of an hour, the amount of time spent on each task must be an integer amount of hours.

As an active learner, Carson has days where he would like to know the max productivity he could've gotten with hours. Help him out!

#### Constraints

For this problem, you will be required to pass all the samples in order to receive any points. In addition, you must pass all previous subtasks to earn points for a specific subtask.

#### Input Specification

The first line contains a single integer , the number of questions.

The next lines describe Carson's questions. The line contains an integer , asking for the max productivity he could've gotten with hours.

#### Output Specification

Output lines, with the line describing the max productivity score Carson could've gotten with hours. Note that a 64-bit integer may be required to print the answer. In C++, this can be done with long long. In Java, this can be done with long. In Python, the standard int will suffice.

#### Sample Input 1

1
7

#### Sample Output 1

12

#### Sample Explanation 1

For the first and only question hours of eating, hours of sleeping, and hours of coding can get Carson a score of .