Pergunta de entrevista da empresa UBS

Explain how XGBoost works, and explain the difference between gradient boosting and bagging.