【问题标题】:How to initialize static variables in python3?如何在python3中初始化静态变量?
【发布时间】:2017-11-19 04:32:35
【问题描述】:

我试图找出一种方法来声明一个变量,其值不能以任何方式更改(c++ 中的静态),但在 python3 中。请告诉我怎么做。

【问题讨论】:

标签: python-3.x variables


【解决方案1】:

在 python3 中无法创建 const 变量,但也有一些选项和建议, 检查下面的链接 - how to set global const variables in python

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2017-05-13
    • 2011-08-22
    • 2010-12-22
    • 1970-01-01
    • 2010-12-11
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多