To print sum of odd numbers in the range entered by the user in python
Answers
Answered by
0
Answer:
sum=0
L=int(input('enter the lower limit'))
U=int(input('enter the upper limit'))
for i in range(L,U+1):
if i %2 != 0 :
sum=sum+i
print('sum of odd no.s :',sum)
Hope You Get It
Similar questions