... len(sys.argv) 來判斷使用者輸入了幾個命令列參數,不符合預期就顯示錯誤訊息並且用 sys.exit() 來結束程式。 Python-sys-argv.py. 1 2 3 4 5 6 7 8 9
確定! 回上一頁