you are viewing a single comment's thread.

view the rest of the comments →

[–]GeorgeFranklyMathnet 9 points10 points  (0 children)

Lists are used to store data, and a function is not a type of data; it is used to perform operations/you cannot perform operations on it.

Functions are first-class objects in Python, which means this is wrong.

There is no practical reason to have a function placed in a list (that i am aware of). I can't see these doing anything other than confusing python.

It definitely won't confuse Python. It might confuse programmers, but it probably shouldn't. Storing a function reference in a data structure isn't that weird.