Changing $foo[$_] with $_ solved the problem. Thanks a lot. Also thank you for the advice about Data::Dumper
In reply to Re^3: split() Problem by Omukawa in thread split() Problem by Omukawa