Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想将“选项”设置为全局:
(options, _) = parser.parse_args()
它是什么类型的?
TIA,
约翰
它不需要使用特定类型的值显式初始化。您只需要使用global关键字:
global
global options (options, _) = parser.parse_args()