foundations of machine learning exercise solutions