此代码仅显示字典列表的最后一项:
def chooseOneServer():
dara = websvc()
i=0
for item in dara:
for key,value in item.items() :
if key == '1' :
servers = ( ('i',value), )
i +=1
return servers
此代码仅显示字典列表的最后一项:
def chooseOneServer():
dara = websvc()
i=0
for item in dara:
for key,value in item.items() :
if key == '1' :
servers = ( ('i',value), )
i +=1
return servers