functions wacky

figured out loop error