题解 | #出生日期输入输出#
出生日期输入输出
http://www.nowcoder.com/practice/4a4a9dd1edb6453ba4a0432319200743
字符串截取
birth=input()
print("year={}\nmonth={:02d}\ndate={:02d}".format(birth[:4],int(birth[4:6]),int(birth[-2:])))
出生日期输入输出
http://www.nowcoder.com/practice/4a4a9dd1edb6453ba4a0432319200743
字符串截取
birth=input()
print("year={}\nmonth={:02d}\ndate={:02d}".format(birth[:4],int(birth[4:6]),int(birth[-2:])))
相关推荐