The old Captain Flint hid the treasures on the island. He has a map of the island, which is a square grid. Each mesh cell contains a number indicating the amount of gold dublons hidden in this cage. Captain Flint left the hint: the treasures are in the chest, buried in the cells of the main diagonal of the card.
rn
You need to Help the pirate team determine the total number of dublons hidden in the chest on the main diagonal of the card.
Input format
the first line contains an integer & nbsp; n & nbsp;-the dimension of the square matrix (maps Islands).
The following & nbsp; n & nbsp; the lines contain on & nbsp; n of integers, separated by spaces, which are a map of the island
Output format
one number-the total number of dublons hidden in the main diagonal of the card
Hint
There will be no clue here, decide for yourself!