[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: try this file ...



 
    
> 
> On Mar 21,  1:37pm, Tianxi Miao wrote:
> > Subject: try this file ...
> > incite                  vt.     <$Fp;R}Fp^M
> > incivility              n.      4VB3^M
> > inclement               a.      ?q7g1)Sj5D^M
> >
> >-- End of excerpt from Tianxi Miao
> 
> 
> #!/usr/bin/perl
> 
> $FILE="<".$ARGV[0];
> open(FILE,$FILE);
> while (<FILE>){
>   chop;
>   print;
> }
> close(FILE);
> 

I was shocked while I was trying your perl prog that I found the
whole Perl directory in "/opt" had been purged by a moron!!!!!!!!!

I temporarily forget where I had downloaded it, so I have to write
a nawk prog.  very luck it works nicely.

thanx for your help.  you will get a gift sooner ;)

My fool code:

# This program should be running with nawk
#
# Usage:
#        nawk -f program textfile
#
 
BEGIN {
 
        getline line

        while ( length(line) ) {

                str = ""
                outline = gsub ("\r", str, line)

                printf "%s", line 
                printf "\n"

                getline line
        }
}



Google