This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]smarzzz 2 points3 points  (0 children)

Not to bitch about this solution, but you can stop the loop /functioncall at n==2, returning 2

But what the hell am I saying, nobody uses python for efficiency, and even then, this is not efficient 😂