Explain the difference between a list and a generator in Python and why it matters for large datasets.
Implement square_values(values) to return a list containing the square of each integer, while using lazy generator iteration internally. The function must preserve input order and may not modify the input list.
Input: a list of integers. Output: a list of squared integers.
Examples: square_values([2, -3]) returns [4, 9]; square_values([]) returns [].
Constraints: 0 <= len(values) <= 100, and each value is between -10^6 and 10^6.
def square_values(values):