in reply to split and print
#!/usr/bin/perl -w use strict; my $var1 = 'abc~123~def'; my @fields = split(/~/,$var1); foreach (@fields) { print "$_\n"; } __END__ abc 123 def
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: split and print (fore!)
by toolic (Bishop) on Sep 04, 2009 at 19:32 UTC | |
by ikegami (Patriarch) on Sep 04, 2009 at 20:22 UTC |