PTA 乙级 1017 A除以B (20分) Python

 这个题拿python做太快了,五行就解决了

利用python不限数据范围的特性

Python

1 num = input()
2 ab = num.split()
3 Q = eval(ab[0]) // eval(ab[1])
4 R = eval(ab[0]) % eval(ab[1])
5 print(Q,R,end = "")

原文地址:https://www.cnblogs.com/SCP-514/p/13236921.html