Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
1
Task/Tokenize-a-string/Perl/tokenize-a-string-1.pl
Normal file
1
Task/Tokenize-a-string/Perl/tokenize-a-string-1.pl
Normal file
|
|
@ -0,0 +1 @@
|
|||
print join('.', split /,/, 'Hello,How,Are,You,Today'), "\n";
|
||||
1
Task/Tokenize-a-string/Perl/tokenize-a-string-2.pl
Normal file
1
Task/Tokenize-a-string/Perl/tokenize-a-string-2.pl
Normal file
|
|
@ -0,0 +1 @@
|
|||
echo "Hello,How,Are,You,Today" | perl -aplF/,/ -e '$" = "."; $_ = "@F";'
|
||||
10
Task/Tokenize-a-string/Perl/tokenize-a-string-3.pl
Normal file
10
Task/Tokenize-a-string/Perl/tokenize-a-string-3.pl
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
BEGIN { $/ = "\n"; $\ = "\n"; }
|
||||
LINE: while (defined($_ = <ARGV>)) {
|
||||
chomp $_;
|
||||
our(@F) = split(/,/, $_, 0);
|
||||
$" = '.';
|
||||
$_ = "@F";
|
||||
}
|
||||
continue {
|
||||
die "-p destination: $!\n" unless print $_;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue