in reply to Re: How to correct code
in thread How to correct code

could you show exact sample wherer should be added "my"?

Replies are listed 'Best First'.
Re^3: How to correct code
by terra incognita (Pilgrim) on Sep 30, 2004 at 14:41 UTC
    Here is a simple brief example, but like dragonchild says, to get the complete picture you should really get a Perl book. Personally I would recommend you borrow, steal or buy the "Camel" book from O'Reilly. It will fill you in on all the stuff necessary to get you going.
    use strict; #declare the variable $foo before using my $foo; $foo = 'hello world'; print $foo;
Re^3: How to correct code
by Crian (Curate) on Sep 30, 2004 at 14:41 UTC
    my @lots_of_thingies; [...] my $all_of_them; foreach my $thingy ( @lots_of_thingies ) { $all_of_them .= $thingy; } print "$all_of_them\n";

    By side, this code cries for join...