3 ms·
> How does it know that range() is zero indexed? If you read through all of the internet once, would you know that range() is zero indexed? > Like, if it was
by MauranKilom 5y ago
> How does it know that range() is zero indexed?
If you read through all of the internet once, would you know that range() is zero indexed?
> Like, if it was looping over 1 billion iterations would it take 1B times longer than if it was just one iteration?
It clearly cannot, because querying the network for a token executes the exact same sequence of operations every time.
But it's very impressive that it can basically recognize the Collatz Conjecture in the code and mostly guess in the right ballpark for the results.
The fact that it's just liking (in a loose sense) inputs to inputs it has seen is quite visible in the f(g(x)) vs g(f(x)) behavior - the former is significantly more common, so it struggles to work with the latter.