TimTim has asked for the wisdom of the Perl Monks concerning the following question:
how to write a program to input a 5 digit number and then seperates the number into its individual digits and prints teh fifth digit 5times, fourth digit 4 times, third digit 3 times and so on.
The output should be like:
enter 5 digit number: 12345
1
22
333
4444
55555
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Five digit number display separately
by choroba (Cardinal) on Sep 04, 2013 at 13:07 UTC | |
Re: Five digit number display separately
by MidLifeXis (Monsignor) on Sep 04, 2013 at 13:08 UTC | |
Re: Five digit number display separately
by hdb (Monsignor) on Sep 04, 2013 at 13:35 UTC | |
Re: Five digit number display separately
by davido (Cardinal) on Sep 04, 2013 at 16:24 UTC | |
by TimTim (Initiate) on Sep 04, 2013 at 21:03 UTC | |
by choroba (Cardinal) on Sep 04, 2013 at 21:35 UTC | |
Re: Five digit number display separately
by BillKSmith (Monsignor) on Sep 04, 2013 at 14:17 UTC |
Back to
Seekers of Perl Wisdom