rodrigoramirez / fibonacci

Code written in different languages to compare relative performance
Apache License 2.0
8 stars 4 forks source link

Only Python works - you forgot to check for int overflow. #1

Open shawndream opened 5 years ago

shawndream commented 5 years ago

https://www.quora.com/What-is-the-100th-term-of-the-Fibonacci-Sequence

https://stackoverflow.com/questions/3001836/how-does-java-handle-integer-underflows-and-overflows-and-how-would-you-check-fo

https://medium.com/@griffinish/integer-overflow-in-golang-9e13e274c8a5

amalshaji commented 5 years ago

https://www.quora.com/What-is-the-100th-term-of-the-Fibonacci-Sequence

https://stackoverflow.com/questions/3001836/how-does-java-handle-integer-underflows-and-overflows-and-how-would-you-check-fo

https://medium.com/@griffinish/integer-overflow-in-golang-9e13e274c8a5

Only python works

sthagen commented 5 years ago

Fixed by reducing 100 to 90 in the implementations 😄