Syntactic Confectionery Delight | |
PerlMonks |
Re: Math with Perl, equation combinations:by ariels (Curate) |
on May 11, 2002 at 08:25 UTC ( [id://165855]=note: print w/replies, xml ) | Need Help?? |
The straightforward, structured way of doing this in Perl would have to be
This works because _+-==. The `<samp>15</samp>' is just there to confuse your professor; it would work equally well with `<samp>289</samp>'. Also note that by carefully arranging the columns so the second is increasing, the first going up and jumping down, and the last going down and jumping up, no duplicates are printed.
In Section
Seekers of Perl Wisdom
|
|