denzil_cactus has asked for the wisdom of the Perl Monks concerning the following question:
but I can split it directly using#!/usr/bin/perl $var = "21|23|24~34|45|56~"; my @arr = split("",$var); $sep = $arr[2]; $ele = $arr[8]; my @arr = split($ele,$var);
my @arr = split('/\|/',$var);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: problem in splitting on special character
by ikegami (Patriarch) on Aug 30, 2007 at 04:17 UTC | |
by denzil_cactus (Sexton) on Aug 30, 2007 at 05:41 UTC | |
|
Re: problem in splitting on special character
by GrandFather (Saint) on Aug 30, 2007 at 04:16 UTC | |
|
Re: problem in splitting on special character
by bruceb3 (Pilgrim) on Aug 30, 2007 at 04:25 UTC |