Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

python program to add two numbers

#create two variable to store the user input number
num1 = int(input('Enter the first number: '))
num2 = int(input('Enter the second number: '))
#create a third variable to store the sum of two no.s
sum = num1 + num2
print('The sum of two entered numbers is:', sum)
Comment

how to add two numbers in python

num1 = int(input('any number'))
num2 = int(input('any number'))
print(sum(num1,num2))
Comment

python program to add two numbers using function

num1 = int(input('Enter the first number: '))
num2 = int(input('Enter the second number: '))
def sum_input(num1,num2):
  sum = num1 + num2
  return sum
Comment

add two numbers in python

# This program adds two numbers

num1 = 1.5
num2 = 6.3

# Add two numbers
sum = num1 + num2

# Display the sum
print('The sum of {0} and {1} is {2}'.format(num1, num2, sum))
Comment

Python of add two numbers

a = int(input("Enter Teh value of a: "))
b = int(input("Enter The value of b: "))

sum = a+b
print(sum)
Comment

python: add two numbers

def add_by_two(numbers):

    return [num + 2 for num in numbers]
    
    
Comment

python how to add 2 numbers

num1 = 2.3
num2 = 1.2
print(num1+num2)
Comment

PREVIOUS NEXT
Code Example
Python :: turtle keep window open 
Python :: drop first column read_csv 
Python :: get dictionary values python 
Python :: python game 
Python :: how to exit program in python 
Python :: python remove empty values from list 
Python :: insert row in any position pandas dataframe 
Python :: open word document python 
Python :: How To Get Redirection URL In Python 
Python :: concat string columns in pandas 
Python :: find pdf encrypted password with python 
Python :: How to get the first and last values from the dataframe column using a function 
Python :: insert single value in dataframe using index 
Python :: how to get a int from string python 
Python :: copy content from one file to another in python 
Python :: python-telegram-bot send file 
Python :: python create dictionary from csv 
Python :: how to sort the dataframe in python by axis 
Python :: pandas loc condition 
Python :: time difference between two datetime.time 
Python :: python to run excel macro 
Python :: determinant of matrix in python 
Python :: python move and rename files 
Python :: Setting up Colab for Kaggle Downloads 
Python :: install glob module in linux 
Python :: python sys.argv 
Python :: python parcourir ligne 
Python :: os chdir python 
Python :: how to run shell command ctrl + c in python script 
Python :: python get env 
ADD CONTENT
Topic
Content
Source link
Name
8+1 =