#!/usr/bin/ksh for month in 05 06 07 08 09; do for object in *; do if [[ -f $object ]] || [[ $object != "core" ]]; then grep -l "$month/" $object >> "$month_test" fi done done