Jefferies Interview Question

What does the Pandas dataframe groupby method return? What are the inputs and outputs of the Pandas dataframe apply method?