Computing.Net > Forums > Unix > Perl Script

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Perl Script

Reply to Message Icon

Name: martint
Date: May 3, 2005 at 22:11:24 Pacific
OS: Red Hat 9
CPU/Ram: 256
Comment:

Can anybody help in writing a perl script that finds each line in a file that contains a specified string. I asked not apply grep to the whole file but loop over the file line by line. The script should print the result in the following format:

Line Number: Line contents

Thanks in advance

martint




Sponsored Link
Ads by Google

Response Number 1
Name: FishMonger
Date: May 4, 2005 at 09:51:59 Pacific
Reply:

This sounds like a homework assignment so, we can't provide you with the script. But if you post your code, we can help guide you.


0
Reply to Message Icon

Related Posts

See More


password reset to the mas... Hex to ascii



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Unix Forum Home


Sponsored links

Ads by Google


Results for: Perl Script

Perl Scripts..search & display www.computing.net/answers/unix/perl-scriptssearch-amp-display/6939.html

perl script - record altering www.computing.net/answers/unix/perl-script-record-altering/3546.html

Equivalent perl script for sed www.computing.net/answers/unix/equivalent-perl-script-for-sed/5939.html