Aman wants to create a program in python to calculate the average marks scored by his friends. He wants to calculate average marks his five friends. Suggest Aman an iterative statement that he can use in the program
Answers
Answered by
2
ANSWER:
for i in num:
sum = sum + i
Explanation:
def average(num):
sum = 0
for i in num:
sum = sum + i
avg = sum / len(num)
return avg
print("The average is", average([65,53,41,57,75]
Similar questions
Social Sciences,
9 days ago
Math,
9 days ago
Geography,
9 months ago
Science,
9 months ago
Chemistry,
9 months ago