Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
x+y+z=17
and I was only permitted to use the numbers 1 through 20, and only 3 numbers at a time, to make this answer, can I possibly get perl to find the question combinations that made up 17?
example output using only nos. 1-20:
combination of using only 3 numbers:
------------------------------------
9+3+5=17
5+5+7=17
8+8+1=17
12+3+2=17
etc...
I've racked my brain for days and I can't clear the cobwebs :-\ Would anyone have any suggestions or pointers on how to do this?
Your wisdom is soooo greatly appreciated, Thank-you
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Math with Perl, equation combinations:
by Zaxo (Archbishop) on May 10, 2002 at 23:08 UTC | |
by samtregar (Abbot) on May 11, 2002 at 03:07 UTC | |
|
Re: Math with Perl, equation combinations:
by ariels (Curate) on May 11, 2002 at 08:25 UTC | |
|
Re: Math with Perl, equation combinations:
by Anonymous Monk on May 12, 2002 at 07:47 UTC |