Programming Examples

Python program to obtain length and breath of a rectangle and calculate its area


Python program to obtain length and breath of a rectangle and calculate its area

Solution

length=float(input("Enter the length of rectangle : "))
breadth=float(input("Enter the breadth of rectangle : "))
area=length*breadth
print("Rectangle  specifications ")
print("Length : ",length," Breadth : ",breadth," Area : ",area)
Output

Enter the length of rectangle : 6

Enter the breadth of rectangle : 5

Rectangle  specifications 

Length :  6.0  Breadth :  5.0  Area :  30.0

Online Exam Quiz for One day Exam Online Typing Test CCC Online Test 2026 Best Computer Training Institute in Prayagraj (Allahabad) Best Java Training Institute in Prayagraj (Allahabad) Best Python Training Institute in Prayagraj (Allahabad) O Level Online Test in Hindi Best Website and Software Company in Allahabad