You are given an undirected connected graph with N vertices and M edges that does not contain self-loops and double edges.   The i-th edge (1 \leq i \leq M) connects Vertex a_i and Vertex b_i.  An edge whose removal disconnects the graph is called a _bridge_.   Find the number of the edges that are bridges among the M edges.
N, M = map(int,input().split())
Edge = [list(map(int,input().split())) for i in range(M)]


def dfs(i):
    visited.add(i)
    for k in From[i]:
        if k not in visited:
            dfs(k)
    for k in To[i]:
        if k not in visited:
            dfs(k)

def bridge(j):
    for i in Edge:
        if i == j:
            continue
        else:
            From[i[0]-1].append(i[1]-1)
            To[i[1]-1].append(i[0]-1)
    dfs(0)
    return True if visited.__len__() != N else False
ans = 0
for j in Edge:
    From = [[] for i in range(N)]
    To = [[] for i in range(N)]
    visited = set()
    ans += bridge(j)
    print(From)
    print(To)
    print(visited)
print(ans)

N, M = map(int,input().split())
Edge = [list(map(int,input().split())) for i in range(M)]


def dfs(i):
    visited.add(i)
    for k in From[i]:
        if k not in visited:
            dfs(k)
    for k in To[i]:
        if k not in visited:
            dfs(k)

def bridge(j):
    for i in Edge:
        if i == j:
            continue
        else:
            From[i[0]-1].append(i[1]-1)
            To[i[1]-1].append(i[0]-1)
    dfs(0)
    return True if visited.__len__() != N else False
ans = 0
for j in Edge:
    From = [[] for i in range(N)]
    To = [[] for i in range(N)]
    visited = set()
    ans += bridge(j)
    #print(From)
    #print(To)
    #print(visited)
print(ans)
