Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Parsing Names in a Text File

by mothra (Hermit)
on Jun 15, 2001 at 20:08 UTC ( #88825=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    open(CUST, "cust_info.txt");
    while (<CUST>) { print ((split ('\|'))[1], "\n"); }
    
  2. or download this
    open(CUST, "cust_info.txt");
    while (<CUST>) {
    ...
        $full_name =~ s/(\w)\w*\s+(.+$)/$1. $2/;
        print $full_name, "\n";
    }
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (3)
As of 2022-06-26 02:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My most frequent journeys are powered by:









    Results (83 votes). Check out past polls.

    Notices?