output_description: Print the number of the edges that are bridges among the M edges.
  
  * * *
input_description: Input is given from Standard Input in the following format:
  
      
      
      N M  
      a_1 b_1  
      a_2 b_2
      :  
      a_M b_M
attempt: import times, strutils, sequtils, math, algorithm, tables, sets, lists, intsets
  import critbits, future, strformat, deques
  template `max=`(x,y) = x = max(x,y)
  template `min=`(x,y) = x = min(x,y)
  let read* = iterator: string {.closure.} =
      while true: (for s in stdin.readLine.split: yield s)
  proc scan(): int = read().parseInt
  proc toInt(c:char): int =
      return int(c) - int('0')
  
  
  var par:seq[int]  
  
  proc root(par:var seq[int], x:int):int=
    if par[x] == x:
      return x
    else:
      par[x] = root(par, par[x])
      result = par[x]
  
  proc unite(par:var seq[int], x,y :int)=
    var
      rx = root(par,x)
      ry = root(par,y)
    if rx == ry:
      return
    else:
      par[rx] = ry
  
  proc same(par:var seq[int], x,y:int):bool=
    return root(par,x) == root(par,y)
  
  
  proc solve():int=
    var
      (n,m) = (scan(),scan())
      usebridges = newseqwith(n,newseq[int](0))
      bridges = newseq[(int,int)](0)
    for i in 0..<m:
      bridges.add( (scan()-1,scan()-1))
  
    for i in 0..<m:
      par = newseq[int](n)
      for j in 0..<n:
        par[j] = j
      for j,b in bridges:
        if i!=j:
          par.unite(b[0],b[1])
      block check:
        for left in 0..<n:
          for right in 0..<n:
            if not par.same(left,right):
              result+=1
              break check
            
  
  
    
    
      
  
      
    
  echo solve()
problem_description: Statement
  
  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.
samples: [{"input": "7 7\n    1 3\n    2 7\n    3 4\n    4 5\n    4 6\n    5 6\n    6 7", "output": "4\n    \n\nThe figure below shows the given graph:\n\n![570677a9809fd7a5b63bff11e5d9bf79.png](https://img.atcoder.jp/abc075/570677a9809fd7a5b63bff11e5d9bf79.png)\n\nThe edges shown in red are bridges. There are four of them.\n\n* * *"}, {"input": "3 3\n    1 2\n    1 3\n    2 3", "output": "0\n    \n\nIt is possible that there is no bridge.\n\n* * *"}, {"input": "6 5\n    1 2\n    2 3\n    3 4\n    4 5\n    5 6", "output": "5\n    \n\nIt is possible that every edge is a bridge."}]