Easy
You are given an undirected star graph of n nodes labeled 1..n. A star graph has one center node connected to every other node, and no other edges. Given its edges, return the label of the center node.
Input: n = 3, edges = [[1,2],[2,3]] Output: 2
Input: n = 4, edges = [[4,1],[4,2],[4,3]] Output: 4