Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL Help?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00044834
Message ID:
00046231
Vues:
50
>>> Where does 109 89 and 91 come from?
>>
>> Should have tested before, Matt is right.
>>
>> Say the solution is x, y and z,
>>then x+y= z and 100x + 10y +10 z + 100 y + 10x + z = 100 z +10y + x
>>
>>I ran my solution but could not have any result. That is because there
>>are so many other possibilities that I do not check. There goes my no
>>nomination for thouroughness I guess.
>>
>It looked like a "diaphantine" equation. I tried to derive such myself, but quickly discovered that creating/solving a diaphantine was more difficult than just programming a little bit (s). BTW, I used 6 FOR loops to solve it...

Hi Bruce,
I used 4 FOR loops to solve it, but I cheated and permutated the 3 digits manually :-). Yours surely more elegant. Nice mental excercise, but I must say it would be nice to formulate a purely mathematical solution form maximum elegance and pure thinking :-).

Bill
William A. Caton III
Software Engineer
MAXIMUS
Atlanta, Ga.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform