https://medium.com/the-code-box-minute/harnessing-the-power-of-python-generators-enhancing-memory-efficiency-in-your-code-9c2dff093bf2