Competitions

# Cities and roads

In the galaxy of "Milky Way" on the planet "Neptune" there are n cities, some of them are connected by roads. Emperor "Maximus" of Galaxy "Milky Way" has decided to make an inventory of roads on the planet "Neptune". But as it turned out he was not good at math, so he asks you to count the number of roads.

#### Input

The first line contains the number n (0n100). Each of the next n lines contains n numbers, each of which is one or zero. Moreover, if the position (i, j) of square matrix is one, then the i-th and j-th city are connected by road, and if zero, it is not connected.

#### Output

Print the number of roads on "Neptune" planet.

Time limit 1 second
Memory limit 128 MiB
Input example #1
5
0 1 0 0 0
1 0 1 1 0
0 1 0 0 0
0 1 0 0 0
0 0 0 0 0

Output example #1
3