UrbanHick has asked for the wisdom of the Perl Monks concerning the following question:
Hello all!
Its another Sunday morning and that means I am trying to get my head around Perl again.
I am looking for an easy way to parse words out of a file that looks like this:
aboveboard aboveground abovementioned abrade Abraham Abram Abramson abrasion abrasive abreact abreast abridge abridgment abroad abrogate abrupt abscess abscissa abscissae absence absent absentee absenteeism absentia absentminded absinthe absolute absolutio +n absolve absorb absorbent absorption absorptive abstain abstention abstinent abstract abstracter abstractor abstruse absurd abuilding abundant abusable abuse abusive abut abutted abutting abysmal abyss Abyssinia AC academe academia academic academician academy Acadia acanthus Acapulco accede accelerate accelerometer accent accentual accentuate accept acceptant acceptor access accessible accession accessory accident accidental accipiter acclaim acclamation acclimate accolade accommodate accompaniment accom +panist
I want to use something like:
my @array = split/\s+/, $scaler;
I have failed to find away to parse this is the pass the individual words on to a while (<>) argument..
My thanks and gratitude in advance to any who can set me straight. -hick
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Parsing individual words from a file
by McDarren (Abbot) on Oct 08, 2006 at 13:28 UTC | |
by UrbanHick (Sexton) on Oct 08, 2006 at 14:01 UTC | |
|
Re: Parsing individual words from a file
by merlyn (Sage) on Oct 08, 2006 at 16:37 UTC | |
by Hue-Bond (Priest) on Oct 08, 2006 at 17:48 UTC |