python运行错误TypeError: unsupported operand type(s) for -: 'str' and 'str'

日期:2021-11-05 13:34:08 人气:1

python运行错误TypeError: unsupported operand type(s) for -: 'str' and 'str'

sys.argv获取的到的参数是字符串,应该使用int()或者float()转换成数字形式才能进行减法操作

热门评论