python获取命令行参数的代码
如下的内容内容是关于python获取命令行参数的内容,希望能对大家有所好处。
# [SNIPPET_NAME: Command line arguments]
# [SNIPPET_CATEGORIES: Python Core]
# [SNIPPET_DESCRIPTION: Prints each command line argument per line]
# [SNIPPET_AUTHOR: Tiago Boldt Sousa <tiagoboldt@gmail.com>]
# [SNIPPET_LICENSE: GPL]
import sys
for x in sys.argv:
print x