On 7/27/07, Rodrigo Tavares <[EMAIL PROTECTED]> wrote: > Hello, > > How I can to make this program, where the variable is > enter though <STDIN>, how separete the digits ? > use split
> > Exercice > 01)Write a program than user type five digits, > separates the individual digits of number, and print > the five digits time five, the four digit four times, > thus for ahead. > #!/usr/bin/perl -w use strict; use warnings; print "Enter a digit: "; my $digit = int(<STDIN>); print map { next unless $_ =~ /^\d+$/; $_ * $_,"\n" } split//,$digit; > Best regards, > > Rodrigo Faria > > > > > > Alertas do Yahoo! Mail em seu celular. Saiba mais em > http://br.mobile.yahoo.com/mailalertas/ > > -- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > http://learn.perl.org/ > > > -- Rodrick R. Brown http://www.rodrickbrown.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/