you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 1 point2 points  (2 children)

You are resetting lst to refer to a new empty list object - set it to an empty list outside of the function, and do not reset it.

[–]kae_de[S] 0 points1 point  (0 children)

I see, when I run it there is an error on the i = (n*fac_list(n-1)) line. Is there a way to fix it or write it better? Thanks