Saturday, 15 February 2020

Sum of two integers

1. Open PyCharm IDE > Right click on Project > New > Python File


2. Give name as SUM > and Click OK



3. Type in your program code

x = int(input("Enter first value: "))
y = int(input("Enter second value: "))
z = x + y
print("Sum is: ", z)

4. Execute the program, clicking Run button or Press Shift+F10

No comments:

Post a Comment