lobs has asked for the wisdom of the Perl Monks concerning the following question:
$currentSenctence is predefined.sub getFeatures { my @tokens = split /\s+/, $_[0]; return @tokens; } if($currentSentence =~ /<@> <s> ([\S\s]+) <head>lines?<\/head> ([\S\s] ++) <\/s> <@>/) { my @temp = getFeatures("$1 $2"); foreach my $variable (@temp) { $features{$variable} ++; } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: assign array to hash
by shmem (Chancellor) on Apr 06, 2016 at 09:55 UTC | |
|
Re: assign array to hash
by Eily (Monsignor) on Apr 06, 2016 at 09:47 UTC | |
|
Re: assign array to hash
by NetWallah (Canon) on Apr 06, 2016 at 21:48 UTC | |
by choroba (Cardinal) on Apr 06, 2016 at 22:15 UTC | |
|
Re: assign array to hash
by Anonymous Monk on Apr 06, 2016 at 08:28 UTC |