Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^3: Solving math equations

by kelan (Deacon)
on Nov 10, 2002 at 05:34 UTC ( [id://211731]=note: print w/replies, xml ) Need Help??


in reply to Re: Re: Solving math equations
in thread Solving math equations

Just a few pointers. You should be using != rather than ne in your while condition. ne is for string comparsion, and != is number comparison. Also, you don't need to increment both numbers. Just increment one, and divide into the total. If there's no remainder, you have one factor, which makes it easy to get the other one.

On a side note, to everyone else who's reading, I can attest that this isn't homework. It's one of the Geek Challenges; the second one, actually. A couple of the higher ones are quite fun.

kelan


Perl6 Grammar Student

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://211731]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (3)
As of 2024-04-25 20:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found