Help for this page

Select Code to Download


  1. or download this
        unless (open(INPUT, "$inputfile"))
        {
        print "ERROR: Can't open file for reading : $!\n";
    
        }
    
  2. or download this
    open INPUT, $inputfile or die "Can't open $inputfile for reading: $!";
    
  3. or download this
        my @data = split("\t", $_);
    
    ...
        my $did2 = $data[1];
        my $score1 = $data[2];
        my $score2 = $data[3];
    
  4. or download this
    my ( $did1, $did2, $score1, $score2 ) = split "\t";
    
  5. or download this
            my $sth1 = $dbh->prepare("select d_id, c_id from d where d_id 
    = '$did1';");
    ...
    = '$did2';");
            
            $sth2->execute();
    
  6. or download this
            my $sth1 = $dbh->prepare("select d_id, c_id from d 
               where d_id = ?");
    ...
            my $sth2 = $dbh->prepare("select d_id, c_id from d 
               where d_id = ?");
            $sth2->execute( $did2 );