in reply to Re^2: split() Problem
in thread split() Problem

Changing $foo[$_] with $_ solved the problem. Thanks a lot. Also thank you for the advice about Data::Dumper