Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Assigning values. Simple and Nasty one.

by blazar (Canon)
on Apr 19, 2005 at 09:54 UTC ( #449165=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl
    #use warnings;
    
  2. or download this
    use strict;
    
  3. or download this
    open my $graph, '<', '2211.txt' or
      die "Can't open `2211.txt': $!\n";
    
  4. or download this
    while (<GRAPH>)
    {
            $a1 = push(@a1, $1);
            $a2 = push(@a2, $2);
        print @a1, @a2;
    }
    
  5. or download this
    while (<GRAPH>)
    {
    ...
            $a2 = $2;
            print $a1, $a2;
    }
    
  6. or download this
    my (@a1, @a2);
    while (<GRAPH>)
    ...
            push @a2, $2;
    }
    print @a1, @a2;
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (5)
As of 2023-01-31 11:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?