Create a Python generator to generate an infinite sequence of a given number.
def generate_infinite_sequence(num):
    while True:
        yield num

for n in generate_infinite_sequence(5):
    print(n)