Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses

Re: Adding Numbers

by PeterPeiGuo (Hermit)
on Nov 21, 2010 at 05:58 UTC ( [id://872754] : note . print w/replies, xml ) Need Help??

in reply to Adding Numbers

Look up perl range operator ..

use Data::Dumper; use strict; use warnings; print "Enter first Number: "; my $ipa = <STDIN>; print "Enter last Number: "; my $ipb = <STDIN>; my @foo = ($ipa..$ipb); print Dumper(@foo);

Peter (Guo) Pei