Killjee has balloons, he is going to his class from his hostel. There are shops between Killjee's class and hostel. The faculty has asked Killjee to bring exactly balloons.
In each shop killjee can sell a balloon, buy a balloon or do nothing. You need to find highest number of balloons killjee can have at any moment during his journey from hostel to class.
INPUT
Input contains 3 integers. , and .
OUTPUT
Print answer to the given problem
CONSTRAINTS
He can buy 1 balloon in first four shop then sell 1 balloon in next 2 shop.