omax problem

can u plz explan how u r getting 19 in the second case…
here is the link OMAX Problem - CodeChef