# Depth Search

Execution time limit is 1 second

Runtime memory usage limit is 128 megabytes

The undirected unweighted graph with one selected vertex is given. Find the number of vertices in the connected component where the selected vertex (including the selected vertex).

## Input

The first line contains the number of vertices $n$ and the selected vertex $s(1≤s≤n≤100)$. In the next $n$ lines given $n$ integers — the adjacency matrix of a graph, where $"0"$ means the absence of an edge, and $"1"$ means the presence of an edge. It is guaranteed that the main diagonal of the matrix contains zeros.

## Output

Print the desired number of vertices.

## Examples

Input #1

Answer #1

Input #5

Answer #5

Submissions 9K

Acceptance rate 53%