Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl
    
    
    use DBI;
    
  2. or download this
    #!/usr/bin/perl
    use warnings;
    use strict;
    use DBI;
    
  3. or download this
    open( FILE, "< $ARGV[0]" );
    
  4. or download this
    open FILE, '<', $ARGV[ 0 ] or die "Cannot open '$ARGV[ 0 ]' $!";
    
  5. or download this
    while ( <FILE> ) {
    
    ...
    
            chomp ($line);
            my @word = split / /, $line;
    
  6. or download this
    while ( my $line = <FILE> ) {
            chomp $line;
            my @word = split ' ', $line;
    
  7. or download this
            $count = 0;
            while ( $word[ $count ] ) {
    ...
                    $word[ $count ] =~ s/\'/\\\'/g;
                    $count++;
            }
    
  8. or download this
            for ( @word ) {
                    tr/^[\-a-zA-Z]//;
                    s/\'/\\\'/g;
            }
    
  9. or download this
    while ( $key = keys %uword ) {