To input length and breadth of rectangle of float type and calculate area of rectangle.
SUBJECT : Artificial Intelligence (AI)
CLASS: 9th
Answers
Answered by
1
Answer:
In python:
length = input ("Enter Length :")
breadth = input ("Enter Breadth :")
area = length * breadth
print("Area :", area)
Explanation:
In python we do not need to declare variables and variable is converted to respective data type when anything is stored in it. So we can directly input decimal number and variable will be of float type.
Similar questions