阅读背景:

如何使变量等于Python中列表中的一个字符串

来源:互联网 

I have been dabbling in Python for a bit and I have come across a problem that I can't seem to solve. I want to have a variable equal one of the strings within a list (the list is passed to the function that the variable is in). I do not want to pin point the exact variable eg. var[0] , but I want Python to search the list for a matching string. I have been dabbling in Python for a bit and I




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: