Question
Write the definition of a method OddSum(NUMBERS) to add those values in the list of NUMBERS, which are odd.
Solution
def OddSum(NUMBERS):
n=len(NUMBERS)
s=0
for i in range(n):
if (i%2!=0):
s=s+NUMBERS[i]
print(s)