Python 3.6.5 (v3.6.5:f59c0932b4, Mar 28 2018, 16:07:46) [MSC v.1900 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
>>> n=input("please enter an integer N:")
please enter an integer N:10
>>> sum=0
>>> for i in range(int(n)):
       sum += i + 1

       
>>> print("1到N求和结果:",sum)
1到N求和结果: 55
>>> 
