bug fix: iterator was being printed regardless of whether it was divisible by 5 or 3