summaryrefslogtreecommitdiff
path: root/progs/a633.py
blob: beb07c01a1c8b0e2b5416f51e148efbb6b02d7d3 (plain)
1
2
3
4
5
6
7
def sum_even_and_even_index(arr,n):  
    i = 0
    sum = 0
    for i in range(0,n,2): 
        if (arr[i] % 2 == 0) : 
            sum += arr[i]  
    return sum