Two-Faced Scorecards

A judge has NN scorecards laid out with their fronts showing. Card ii has score aia_i on its front and bib_i on its back. The total score is the sum of the visible values.

The judge may turn over any selection of cards, but an even number of cards must finish with their backs showing. Zero is even, so leaving every card alone is allowed.

What is the largest possible total score?

Input

The first line contains NN.

The next NN lines each contain aia_i and bib_i for one card.

Output

Print the maximum total score.

Constraints

Notes

In Sample 1, show the backs of cards 11 and 33. The score is 8+6+4=188+6+4=18.

In Sample 2, show the backs of cards 11 and 22. The score is 5+3+7=155+3+7=15. Choosing each larger value independently would leave an odd number of backs showing.

Sample Input 1 Sample Output 1
3
3 8
6 5
4 4
18
Sample Input 2 Sample Output 2
3
1 5
4 3
7 6
15