CSES - HIIT Open 2016 Practice

## HIIT Open 2016 Practice

 Contest start: 2016-05-19 17:00:00 Contest end: 2016-05-28 9:00:00

 Instructions

Submission

You must submit the source code of your program. After the submission, your code will be compiled and tested on the server. Your code will be accepted, if it solves each test within given time and memory limits.

The score for your team is the number of accepted tasks. In addition, there is a time penalty that is the sum of submission times for accepted tasks in minutes. If two teams have solved the same number of tasks, the team whose time penalty is lower is considered better. For each wrong submission, you get 20 minutes extra penalty time for the task (if you eventually can solve it).

Time and memory limits for the tasks are given in task statements. The maximum size for the source code is 128 kB.

I/O

Your program must read from the standard input and write to the standard output, unless otherwise stated.

In C++, you can use the following code for more efficient I/O:
ios_base::sync_with_stdio(0);
cin.tie(0);
In Java, you can use the class IO.java for efficient I/O. The class will be compiled with your program on the server.

Here is an example how to use IO.java:
public class Solution {
public static void main(String[] args) {
IO io = new IO();
int a = io.nextInt();
int b = io.nextInt();
io.println(a+b);
io.close(); // ALWAYS CALL THIS
}
}
Compilers

The C++ compiler is g++ 4.8.4. Compiler flags are -std=c++11 -O2 -Wall.

The Java compiler is Oracle javac 1.8.0_74.

The Scala compiler is version 2.11.6.

The Haskell compiler is GHC 7.6.3.