01 Joe
02 Ed
03 Sam
04 Wendy
####
yadda 01 abc
yadda 03 sss
yadda 02 asdsdbc
yadda 02 adfgbc
yadda 01 abgxvc
yadda 02 azdfbc
yadda 04 azdfbc
yadda 04 abdc
####
foreach (@transactions) { #there are dozens of employee numbers…
if ($_ eq 01) { push (@joe , $_) ; }
if ($_ eq 02) { push (@ed , $_) ; }
if ($_ eq 03) { push (@sam , $_) ; }
if ($_ eq 04) { push (@sam , $_) ; }
if (no others) { push (@unregistered , $_) ; }
}
####
foreach (@transactions) {
push (@the_correct_employee’s_array_based_on_number , $_) ;
}