Write a python program to add two numbers

In this source code example, we write a python program to add two numbers.

Write a python program to add two numbers

a=int(input("enter the value for a => "))
b=int(input("enter the value for b => "))
c=a+b
print("The sum of a and b is",c)

Output:

enter the value for a => 10
enter the value for b => 20
The sum of a and b is 30

Comments