一、格式化输入与输出
python2与python3中的输入输出格式不同,且python2不能直接输出汉字,需要添加【# _*_coding:utf-8_*_】来定义编码格式
python2
输入: input() ##输入整型
raw_input() ##输入字符型
输出: print ''
python3
输入: input()
输出: print('')
(1)输出print
(2)输入input
python2的输入
python3的输入
(3)利用函数实现格式化输出