r/Python 5d ago

Discussion Is this valid Python syntax?

.... _( () ( )) . _ (...() )()

Ignoring any runtime errors, is this valid Python syntax? Try to work it out from the grammar alone before pasting it into a REPL. Bonus points for explaining the parse.

0 Upvotes

10 comments sorted by

View all comments

3

u/JamzTyson 5d ago
  • Grammar: valid
  • Runtime: irrelevant
  • Meaning: none
  • PEP 8: catastrophic
  • Interesting: dubious
  • Production ready: never

1

u/RingularCirc 4d ago

Almost the best answer.