Re: Not getting all the element.

2008-12-04 Thread Randal L. Schwartz
> "slow" == slow leaner <[EMAIL PROTECTED]> writes: slow> while (<@numbers>){ Meta question: Did you see this combination of <@...> on a web page or book somewhere, and if so, where? Or did you construct this through some thought process, and if so, can you explain it? I keep seeing th

Re: Not getting all the element.

2008-11-29 Thread John W. Krahn
slow_leaner wrote: Hello all, Hello, what am i missing!!! #!/usr/bin/perl -w @array_number =; @new_array = half( @array_number ); print "@new_array\n"; sub half { @numbers = @_; while (<@numbers>){ That is short for: while ( defined( $_ = glob join $", @numbers ) ) {

Re: Not getting all the element.

2008-11-29 Thread Mr. Shawn H. Corey
On Fri, 2008-11-28 at 11:56 -0800, slow_leaner wrote: > Hello all, what am i missing!!! > #!/usr/bin/perl -w > @array_number =; > @new_array = half( @array_number ); > print "@new_array\n"; > > sub half { > @numbers = @_; > while (<@numbers>){ > @n = $_ / 2; > @new_a = pop(@n)