Question 472: What is a generator?
tcs
wipro
infosys
general
aptitude
generators
python-programming
In Python, a generator is a type of iterable, similar to a list or tuple, but it allows lazy evaluation of values. It generates values on-the-fly and does not store them in memory all at once, making it memory-efficient.