I don't understand why there are 74 BP for an inefficent solution when there are way better solutions submitted. Not insulting the code, I did the same thing before realising the loop was unessesary.
I am getting errors in python where the answer is so big that python thinks it is +ve infinity. Anyone know how to solve this? My code completes all of the tests it can do very fast and I can see no way of making it more efficent.
This comment is hidden because it contains spoiler information about the solution
I don't understand why there are 74 BP for an inefficent solution when there are way better solutions submitted. Not insulting the code, I did the same thing before realising the loop was unessesary.
I am getting errors in python where the answer is so big that python thinks it is +ve infinity. Anyone know how to solve this? My code completes all of the tests it can do very fast and I can see no way of making it more efficent.
You don't need the [] inside the sum(), as sum accepts a generator expression.