首页 新闻 会员 周边
6
回答数

待解决问题 5 python函数问题

def f(x): x = 100 print x f(x) #这样子调用为什么不行? def f(): x = 100 print x f() #这样子调用为什么行?
2
回答数

已解决问题 5 字典同时取对应的key和value

dict = {"a" : "apple", "b" : "banana", "g" : "grape", "o" : "orange"} 我想得到结果 a:apple
3
回答数

已解决问题 5 python3 的index疑问

m = [1,2,3,4,34,4,5,6] n = m.index(4,4,6) print(n) 这个结果为什么是5 ?