Computer Science, asked by Princedynamic9987, 7 months ago

Write a algorithm calculate the average of an n integer , checking weather number is odd or even

Answers

Answered by RuwaisnZaid
0

Explanation:

n = int(input ("enter a no"))

for i in range(n):

sum+=i

avg = sum/n

if avg%2=0:

print("even")

elif avg%2!=0:

print("odd")

else:

print("wrong int")

mark me as brainly

Similar questions