Project Euler #9 In Python

Pubblicato il: 01 aprile 2021
sul canale di: Dubious Code
96
0

Python solution to project euler problem 9 from here https://projecteuler.net/problem=9

This was a fun one. We know a 3,4,5 triangle. It turns out there are other perfect squares. So we find every combination of positive a,b,c where a+b+c = 1000 and then check if a^2 + b^2 = c^2.

I ran A and B up to 500 but I suspect it could have been less since C needed to be greater than A or B

All code

Copyright 2021 Google LLC
SPDX-License-Identifier: Apache-2.0
https://www.apache.org/licenses/LICEN...

The Snake image in the thumbnail - by Vecteezy https://www.vecteezy.com/vector-art/4...


In questa pagina del sito puoi guardare il video online Project Euler #9 In Python della durata di ore minuti seconda in buona qualità , che l'utente ha caricato Dubious Code 01 aprile 2021, condividi il link con amici e conoscenti, su youtube questo video è già stato visto 96 volte e gli è piaciuto 0 spettatori. Buona visione!