a,b =input('输入a,b空格隔开:').split() #此时a,b为str型 a,b =map(int,input('输入a,b空格隔开:').split()) #此时a,b为int型 备注:转换成int类型需要用map函数!