`final` keyword equivalent for variables in Python?

后端 未结 11 2169
忘了有多久
忘了有多久 2021-01-30 20:17

I couldn\'t find documentation on an equivalent of Java\'s final in Python, is there such a thing?

I\'m creating a snapshot of an object (used for restorati

11条回答
  •  独厮守ぢ
    2021-01-30 20:48

    Python has no equivalent of "final". It doesn't have "public" and "protected" either, except by naming convention. It's not that "bondage and discipline".

提交回复
热议问题