From: Pandey Rajeev-A19514 <[EMAIL PROTECTED]> > I am new to perl and need some help. > > How do we pass array of scalars to a subroutine. > I need something like this > > *************************************** > sub ABC { > my(@buffer) shift; > print @buffer;
my $buffer = shift; print @$buffer; > } > > I want to call this subroutine from some other code like. > > ABC( @this_buffer ); ABC( [EMAIL PROTECTED] ); You have to read about references: perldoc perlreftut perldoc perlref HTH, Jenda ===== [EMAIL PROTECTED] === http://Jenda.Krynicky.cz ===== When it comes to wine, women and song, wizards are allowed to get drunk and croon as much as they like. -- Terry Pratchett in Sourcery -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]