Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
8 views2 pages

Problem Statement 5

The document outlines a Python program designed to perform basic arithmetic operations such as addition, subtraction, multiplication, division, modulus, and exponentiation. It includes a problem statement, objectives, and a source code example that prompts the user for two numbers and displays the results of the operations. An example output is provided, demonstrating the program's functionality with sample inputs.

Uploaded by

adithapa129
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views2 pages

Problem Statement 5

The document outlines a Python program designed to perform basic arithmetic operations such as addition, subtraction, multiplication, division, modulus, and exponentiation. It includes a problem statement, objectives, and a source code example that prompts the user for two numbers and displays the results of the operations. An example output is provided, demonstrating the program's functionality with sample inputs.

Uploaded by

adithapa129
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

Student name- Sachin Page-5

Roll no- 48 D.O.P-19/09/2025


Course- BCA AI&DS

PROBLEM STATEMENT 5- Write a python program to implement arithmetic


Operation.
OBJECTIVE- To understand the implementation of various arithmetic
Operation.
EXPLANATION- Arithmetic operations are the basic mathematical operations
that we used to perform calculations on numbers. They form the foundation
of mathematics and are used in almost every field of study.
SOURCE CODE-
a = int(input("Enter first number: "))
b = int(input("Enter second number: "))

# Performing arithmetic operations


print("\nArithmetic Operations:")
print("Addition: ", a + b)
print("Subtraction: ", a - b)
print("Multiplication: ", a * b)
print("Division: ", a / b if b != 0 else "Undefined (division by zero)")
print("Modulus: ", a % b if b != 0 else "Undefined (modulus by zero)")
print("Exponentiation: ", a ** b)
Student name- Sachin Page-5
Roll no- 48 D.O.P-19/09/2025
Course- BCA AI&DS

OUTPUT-
Enter first number: 10
Enter second number: 3

Arithmetic Operations:
Addition: 13
Subtraction: 7
Multiplication: 30
Division: 3.3333333333333335
Modulus: 1
Exponentiation: 1000

You might also like