human
Write a function to find common first element in given list of tuple. Here is a solution in Python:
=====
What is a Python code to find common first element in given list of tuple?
assistant
#Here is Python code to find common first element in given list of tuple.
 def group_tuples(Input): 
	out = {} 
	for elem in Input: 
		try: 
			out[elem[0]].extend(elem[1:]) 
		except KeyError: 
			out[elem[0]] = list(elem) 
	return [tuple(values) for values in out.values()]