in reply to Problem using | char as delimiter for split

| is the alternation operator within a regular expression. For example foo|bar matches "foo" or "bar".

If you want to split using it, you need to escape it with a \

my($num1,$num2,$num3,$num4,$num5)=split(/\|/,$a);