Frage im Vorstellungsgespräch bei Doximity

What is generator and yield in python. Difference between class and function in python.