It Works!!

Made it so the loops actually work it was a problem with fflush.