Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add files via upload #105

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions activity1.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#python program to add two numbers using a function

def add_num(a,b):#function for addition
sum=a+b;
return sum; #return value
num1=int(input("Enter the first value: "))#input from user for num1
num2=int(input("Enter the second value: "))#input from user for num2

print("The sum is",add_num(num1,num2))#call the function