Generators

comparison between generators and regular functions, use case of a generator

We'll cover the following...

A generator is a special function that returns an iterator. There are some differences between generator functions and regular functions:

  • There is an * after the function keyword.
  • Generator
...