output_description: Print an integer representing the minimum total travel expense.
  
  * * *
input_description: Input is given from Standard Input in the following format:
  
      
      
      N A B
attempt: import queue
  
  n, k = map(int, input().split())
  edges = []
  for _ in range(n - 1):
      edges.append(list(map(int, input().split())))
  
  mod = 10**9 + 7
  edge_dict = {}
  for i in range(1, n + 1):
      edge_dict[i] = set()
  
  for edge in edges:
      edge_dict[edge[0]].add(edge[1])
      edge_dict[edge[1]].add(edge[0])
  
  visited = set()
  q = queue.LifoQueue()
  q.put(1)
  
  while not q.empty():
      node = q.get()
      visited.add(node)
      print("Visit %d" % node)
  
      for child in edge_dict[node] - visited:
          q.put(child)
  
problem_description: Statement
  
  N of us are going on a trip, by train or taxi.
  
  The train will cost each of us A yen (the currency of Japan).
  
  The taxi will cost us a total of B yen.
  
  How much is our minimum total travel expense?
samples: [{"input": "4 2 9", "output": "8\n    \n\nThe train will cost us 4 \\times 2 = 8 yen, and the taxi will cost us 9 yen, so\nthe minimum total travel expense is 8 yen.\n\n* * *"}, {"input": "4 2 7", "output": "7\n    \n\n* * *"}, {"input": "4 2 8", "output": "8"}]