Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: extracting specific information from a txt file

by apl (Monsignor)
on Aug 24, 2010 at 12:22 UTC ( #856920=note: print w/ replies, xml ) Need Help??


in reply to extracting specific information from a txt file

Write a small program that opens the text file, reads it line by line, and prints out each line read.

Then modify it to count the number of characters in each line.

Then modify it to count the number of words in each line.

Then modify it to find a string containing @.

Then modify it to generalize the search to look for an e-mail address (text@text.tla).

Then modify it to look for a number after the e-mail address.

Then modify it to read blocks of text separated by % (rather than by line).

Show us the code that presents a problem to you, and we'll be glad to help.


Comment on Re: extracting specific information from a txt file

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://856920]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (5)
As of 2014-08-30 12:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (293 votes), past polls