Discuss / Python / 我也交作业来咯

我也交作业来咯

Topic source

小O_园子

#1 Created at ... [Delete] [Delete and Lock User]

#!/usr/bin/env python3

s1 = input('Last year score:') s2 = input('This year score:') inc = (int(s2) - int(s1))/int(s1) * 100 print("Increment = %.1f%%" % inc)

输出结果

Last year score:76
This year score:83
Increment = 9.2%

  • 1

Reply