Problem:


Score : 200 points

Problem Statement

We have N squares assigned the numbers 1,2,3,\ldots,N. Each square has an integer written on it, and the integer written on Square i is a_i.

How many squares i satisfy both of the following conditions?

The assigned number, i, is odd.

The written integer is odd.

Constraints

All values in input are integers.

1 \leq N, a_i \leq 100

Input

Input is given from Standard Input in the following format:

N
a_1 a_2 \cdots a_N

Output

Print the number of squares that satisfy both of the conditions.

Sample Input 1

5
1 3 4 5 7

Sample Output 1

2

Two squares, Square 1 and 5, satisfy both of the conditions.

For Square 2 and 4, the assigned numbers are not odd.

For Square 3, the written integer is not odd.

Sample Input 2

15
13 76 46 15 50 98 93 77 31 43 84 90 6 24 14

Sample Output 2

3



Sample input:
5
1 3 4 5 7


Sample output:
2

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))
cnt = 0

for i in range(len(a)):
    if i%2 == 0:
        if a[i]%2 == 1:
            cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
N = int(input())
a_i = list(map(int, input().split()))
ans = 0
for i in range(N):
  if (i+1)%2 == 1 & a_i[i]%2 == 1:
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
from math import *
n=int(input())
a=list(map(int,input().split()))
ans=0
for i in range(0,n,2):
    if a[i]%2!=0:
        ans=ans+1
print(ans)

Submission status: Accepted

Solution code:
a=input()
b=map(int,input().split())
c=list(b)
i=0
j=1

for k in c:
  if j%2==1 and int(k)%2==1:
    i +=1
  j +=1
print(i)

Submission status: Accepted

Solution code:
n = int(input())
a_list = list(map(int,input().split()))
sum = 0
for i in range(0,n,2):
    if(a_list[i] % 2 != 0):
        sum += 1
print(sum)

Submission status: Accepted

Solution code:
n = int(input())
x = list(map(int, input().split()))
c = 0
for i in range(n):
    if i%2 == 0 and x[i]%2 == 1:
        c += 1
print(c)

Submission status: Accepted

Solution code:
#import numpy as np
#import math
#from decimal import *
#from numba import njit

#@njit
def main():
    N = int(input())
    a = list(map(int, input().split()))

    count = 0
    for i in range(N):
        if (i+1)%2 == 1 and a[i]%2 == 1:
            count += 1

    print(count)

main()

Submission status: Accepted

Solution code:
n=int(input())
ali = list(map(int,input().split()))
result = 0
for a in ali[::2]:
  if a % 2 == 1:
    result += 1
print(result)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))

b = []
for i in range(n):
    if (i + 1) % 2 == 1 and a[i] % 2 == 1:
        b.append(i)

print(len(b))

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))

cnt = 0
for i in range(len(a)):
    if i % 2 == 0 and a[i] % 2:
        cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
N = int(input())
a = [int(x) for x in input().split()]

C=0

for i in range(1,N+1):
    if i%2!=0:
        if a[i-1]%2!=0:
            C+=1

print(C)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))
count = 0
for i in range(0, n):
  if (i+1)%2 == 1 and a[i]%2 == 1:
    count += 1
print(count)

Submission status: Accepted

Solution code:
import numpy as np

N = input()
l = list(map(int, input().split()))
count= 0
count2 = 0

for i in l:
    if (count % 2 == 0) and (i % 2 == 1):
        count2 += 1
    count += 1


print(count2)

Submission status: Accepted

Solution code:
n=int(input())
a=list(map(int,input().split()))
print(len([a[i] for i in range(n) if i%2==0 and a[i]%2]))

Submission status: Accepted

Solution code:
n = int(input())
li = list(map(int,input().split()))
counter = 0
for i in range(n):
    if i % 2 == 0 and li[i] % 2 != 0:
        counter += 1


print(counter)

Submission status: Accepted

Solution code:
n = int(input())
a = list( map( int, input().split() ) )

i = 0
ans = 0
while i < n:
  if a[i] % 2 == 1:
    ans += 1
  i += 2

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
l = map(int, input().split())
result = []
for index, i in enumerate(l, start=1):
    if index % 2 == 1 and i % 2 == 1:
        result.append(i)
print(len(result))

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int,input().split()))
ans = 0
for i in range((N+1)//2):
    if a[2*i]%2 == 1:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
A = [int(n) for n in input().split()]

count = 0
for offset in range(N):
    if offset % 2 == 0:
        if A[offset] % 2 == 1:
            count += 1
        else:
            pass
    else:
        pass

print(count)

Submission status: Accepted

Solution code:
N = int(input())
a=list(map(int, input().split()))
ans = 0
for i in range(0, N, 2):
    if (a[i] % 2 == 1):
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
if __name__ == '__main__':
    N = int(input())
    a = list(map(int,input().split()))

    count = 0
    for i,k in enumerate(a):
        if i%2 == 0 and k%2==1:
            count += 1

    print(count)

Submission status: Accepted

Solution code:
n = int(input())
A = list(map(int,input().split()))
B = []
for i in range(n):
    if (i+1)%2 == 1:
        B.append(A[i])
cnt = 0
for i in B:
    if i % 2 == 1:
        cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
n=int(input())
a=list(map(int,input().split(" ")))
c=0
for i in range(0,n,1):
    if ((i+1)*(i+1))%2!=0 and a[i]%2!=0:
        c+=1
print(c)

Submission status: Accepted

Solution code:
N = input()
a = list(map(int,input().split()))
odd = a[::2]
count = 0
for i in odd:
  if i % 2 == 1:
    count += 1
  else:
    pass
print(count)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))

ans = 0
for i in range(N):
    if a[i] % 2 == 1 and i % 2 == 0:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
import numpy as np

N = int(input())
a = np.array([int(s) for s in input().split()])

odd = a[0::2]
print(np.count_nonzero(odd%2 == 1))

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))
count = 0
for i in range(0, N, 2):
    if a[i] % 2 == 1:
        count += 1
print(count)

Submission status: Accepted

Solution code:
n = int(input())
numlist = list(map(int,input().split()))
ans = 0
for i in range((n-1)//2+1):
    if numlist[i*2] % 2 == 1:
        ans += 1
        
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))
ret = 0
#N = 5
# = [1,3,4,5,7]
for i in range(0, N, 2):
    if a[i] % 2 != 0: ret += 1

print(ret)

Submission status: Accepted

Solution code:
N=int(input())
A=list(map(int, input().split(' ')))
u=0
for i in range(N):
    if i%2==0 and A[i]%2==1:
        u=u+1
print(u)

Submission status: Accepted

Solution code:
n=int(input())
a = list(map(int,input().split()))
count=0
for i in range(n):
    if (i+1)%2==1 and a[i]%2==1:
        count=count+1
print(count)

Submission status: Accepted

Solution code:
ii = int(input())
inss = input().split(" ")
t = 0
for i in range(ii):
  inp = int(inss[i])
  if (i+1) % 2 != 0 and inp % 2!= 0:
    t += 1
  

print(t)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))
#a = [list(map(int, list(input()))) for i in range(N + 1)]
# L, R, d = map(int, input().split())
cnt = 0
for i in range(0, N, 2):

    if a[i] % 2 != 0:
        cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
ans = 0
for i in range(N):
    if i % 2 == 0 and A[i] % 2 == 1:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))
cnt = 0
for i in range(N):
    if (i + 1) % 2 == 1:
        if a[i] % 2 == 1:
            cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))

count = 0

for i, a in enumerate(A):
  if (i+1)%2 and a%2:
    count += 1
print(count)

Submission status: Accepted

Solution code:
x=int(input())
y=list(map(int, input().split()))
res=0
for i in range(0,x,2):
  if y[i]%2:
    res+=1
print(res)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int,input().split()))

count = 0
for i,j in enumerate(a,1):
    if i % 2 == 1 and j % 2 == 1:
        count += 1
        
print(count)

Submission status: Accepted

Solution code:
n=int(input())
a=list(map(int,input().split()))
ans=0
for i in range((n+1)//2):
  if a[2*i]%2==1:
    ans+=1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
b = input().split()
a = []
c = []
for i in range(N):
    if i % 2 == 0:
        a.append(int(b[i]))
for i in range(len(a)):
    if a[i] % 2 == 1:
        c.append(a[i])
print(len(c))

Submission status: Accepted

Solution code:
n = int(input()) 
a = list(map(int,input().split())) 

odd = a[0::2]
ans = 0
for i in range(len(odd)):
    if odd[i]%2 == 1:
        ans = ans + 1
print(ans)

Submission status: Accepted

Solution code:
a = int(input())
n = list(map(int, input().split()))
odds = n[0::2]
count = 0

for i in odds:
  if i%2 != 0:
    count += 1
  else:
    count += 0
    
print(count)

Submission status: Accepted

Solution code:
n=int(input())
a=[int(i) for i in input().split()]
ans=0
for i in range(len(a)):
  if (i+1)%2 and a[i]%2:
    ans+=1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
ans = 0
for i in range(1,N+1):
    if (i%2) == 1:
        if (A[i-1]%2) == 1:
            ans = ans + 1
print(ans)

Submission status: Accepted

Solution code:
n = int(input())

numbers = list(map(int, input().split()))

ans = len([i for i, number in enumerate(numbers, 1) if (i % 2 == 1) and (number % 2 == 1)])

print(ans)

Submission status: Accepted

Solution code:
#coding: UTF-8
N = int(input())
#print(N)

a = [0]*N

a = list(map(int, input().split()))
#print(a)
cnt = 0

#マスの番号が奇数＝配列偶数個目
for i in range(N):
  if i%2==1:
    continue
  
  #数字が奇数
  if a[i]%2==1:
    cnt += 1


print(cnt)

Submission status: Accepted

Solution code:
N=int(input())
A=list(int(x) for x in input().split())
count=0
for i in range(N):
	if i%2==0 and A[i]%2!=0:
		count+=1
print(count)

Submission status: Accepted

Solution code:
N = input()
del N
I1 = input().split(); i = 0
for a in range(len(I1)):
    if (int(I1[a]) * (a+1))%2 == 1:
        i += 1
print(i)

Submission status: Accepted

Solution code:
N = int(input())
l = input().split()
ans = 0
if N%2 ==0:
    for i in range(N//2):
        if int(l[2*i])%2 == 1:
            ans += 1
    print(ans)

else:
    for i in range(N//2+1):
        if int(l[2*i])%2 == 1:
            ans += 1
    print(ans)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int,input().split()))

f = 0
for i in range(N):
    if ((i+1)%2==1) and (a[i]%2==1):
        f = f + 1

print(f)

Submission status: Accepted

Solution code:
N=int(input())
*a,=map(int,input().split())
a=[0]+a
count=0
for i in range(1,N+1):
  if i%2==1 and a[i]%2==1:
    count+=1
    
print(count)

Submission status: Accepted

Solution code:
from sys import stdin
n = int(stdin.readline().rstrip())
data = list(map(int, stdin.readline().rstrip().split()))

count = 0
data.insert(0, 0)

for i in range(0,len(data)//2):

    if data[2*i+1]%2 == 1:
        count += 1

print(count)

Submission status: Accepted

Solution code:
youso = int(input())
words = input()
numbers = words.split()
for i in range(youso):
    numbers[i] = int(numbers[i])
    
answer = 0

for j in range(youso):
    if j % 2 == 0 and numbers[j] % 2 == 1:
        answer += 1

print(answer)

Submission status: Accepted

Solution code:
import numpy as np

N = int(input())
a = list(map(int, input().split()))

a2 = np.array([a[i*2] for i in range(int(np.ceil(N/2)))])
print(np.sum(a2 % 2))

Submission status: Accepted

Solution code:
n=int(input())
ans=0
l=list(map(int,input().split()))
for i in range(len(l)):
    if((i+1)%2!=0 and l[i]%2!=0):
        ans+=1 
print(ans)

Submission status: Accepted

Solution code:
n = int(input())
A = list(map(int, input().split()))

cnt = 0
for i in range(1, n+1, 2):
  if A[i-1] % 2 != 0:
    cnt += 1
    
print(cnt)

Submission status: Accepted

Solution code:
N = int(input()) #1行目のNを取得する
A = list(map(int,input().split())) 

result = 0

for i in range(N):
    if (i+1) % 2 == 1 and A[i] % 2 == 1:
        result += 1

print(result)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline

n = int(input())
a = [0] + list(map(int, input().split()))

a = [a[i] for i in range(n+1) if i%2==1 and a[i]%2==1]
print(len(a))

Submission status: Accepted

Solution code:
'''Author- Akshit Monga'''
t=1
for _ in range(t):
    n=int(input())
    arr=[int(x) for x in input().split()]
    ans=0
    for i in range(0,n,2):
        if arr[i]%2!=0:
            ans+=1
    print(ans)

Submission status: Accepted

Solution code:
n = int(input())
arr = list(map(int,input().split()))

ans = 0
for i in range(n):
    if i %2 == 0 and arr[i]%2 == 1:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split(' ')))
n = 0
for i in range(N):
    if (i+1)%2 != 0:
        if a[i]%2 != 0:
            n += 1
print(n)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))
ans = 0

for i in range(0,N,2):
    if a[i] ==1:
        ans += 1
    elif a[i]%2 ==1:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))
cnt = 0

for i in range (N):
  if (i+1) % 2 != 0:
    if a[i] %2 != 0:
      cnt += 1
      
print(cnt)

Submission status: Accepted

Solution code:
N = int(input())
ar = list(map(int, input().split()))

cnt = 0
for i in range(N):
    if i % 2 == 0 and ar[i] % 2 == 1:
        cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
N = int(input())
l = list(map(int,input().split()))

c = 0

for i in range(N):
    if i % 2 == 0 and l[i] % 2 == 1:
        c += 1

print(c)

Submission status: Accepted

Solution code:
def AnOddProblem():

    num = int(input())
    
    num_1 = list(map(int,input().split()))

    count = 0

    for i in range(num):
        mod_1 = num_1[i] % 2
        mod_2 = (i + 1) % 2
        
        if mod_1 == 1 and mod_2 == 1:
            count = count + 1
    
    print(count)

if __name__ == '__main__':
    AnOddProblem()

Submission status: Accepted

Solution code:
N = int(input())
L = list(map(int, input().split()))
num=0
for i in range(N):
    if i%2==0 and L[i]%2==1:
        num+=1
print(num)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))

ans = 0

for i in range(0,n,2):
    if a[i] % 2 != 0:
        ans +=1

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
ans = 0
for i, a in enumerate(A):
    if (i+1) % 2 == 1 and a % 2 == 1:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
result = 0
for i in range(N):
  if i % 2 == 0:
    if A[i] % 2 != 0:
      result += 1
print(result)

Submission status: Accepted

Solution code:
import sys

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

N, *A = map(int, read().split())

ans = 0
for i, x in enumerate(A):
    if i % 2 == 0 and x % 2 == 1:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
n = int(input())
A = [int(x) for x in input().split()]
print(sum(a%2 and b%2 for a,b in zip(A,range(1,n+1))))

Submission status: Accepted

Solution code:
n = int(input())
ls = list(map(int, input().split()))

ans = 0
for i, ele in enumerate(ls):
    if (i+1)%2 != 0:
        if ele%2 != 0:
            ans += 1
print(ans)

Submission status: Accepted

Solution code:
# 
import sys

from sys import stdin
input = lambda: stdin.readline().rstrip()

N = int(input())
a = list(map(int,input().split()))

cnt = 0
for i in range(len(a)):
    if (i + 1) % 2 != 0 and a[i] % 2 != 0:
        cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
n=int(input())
l=list(map(int,input().split()))
l=l[0::2]
a=0
for i in l:
    if(i%2==1):
        a+=1
print(a)

Submission status: Accepted

Solution code:
N=input()
a = list(map(int,input().split()))
s = 0
for i in range(len(a))[::2]:
    if(a[i]%2==1):
        s = s + 1
print(s)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int,input().split()))
b = 0
for i in range(N):
    if (i+1) % 2 != 0 and a[i] % 2 != 0:
        b += 1

print(b)

Submission status: Accepted

Solution code:
def resolve():
    import sys
    sys.setrecursionlimit(10 ** 6)  # 再帰関数の再帰の深さを設定
    to_index = lambda x: int(x) - 1  # 入力した数字に1を引いたものを返す
    print_list_in_2D = lambda x: print(*x, sep="\n")  # リストの要素を改行を挟んで表示する関数

    # 入力を整数に変換して受け取る
    def input_int():
        return int(input())

    def map_int_input():
        return map(int, input())

    MII = map_int_input

    def MII_split():
        return map(int, input().split())

    def MII_to_index():
        return map(to_index, input())

    def MII_split_to_index():
        return map(to_index, input().split())

    # 入力全てを整数に変換したものの配列を受け取る
    def list_int_inputs():
        return list(map(int, input()))

    LII = list_int_inputs

    def LII_split():
        return list(map(int, input().split()))

    # 2次元リスト化
    def LII_2D(rows_number):
        return [LII() for _ in range(rows_number)]

    def LII_split_2D(rows_number):
        return [LII_split() for _ in range(rows_number)]

    N = input_int()
    a_list = LII_split()

    ans = 0
    for i in range(N):
        if i % 2 == 0 and a_list[i] % 2 == 1:
            ans += 1
    print(ans)
resolve()

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
res = 0
for i in range(0, len(A), 2):
    res += A[i] % 2
print(res)

Submission status: Accepted

Solution code:
N = int(input())
A = [int(s) for s in input().split()]

count = 0
for i in range(0, N, 2):
  if A[i] % 2 == 1:
    count += 1
    
print(count)

Submission status: Accepted

Solution code:
#!/usr/bin/env python
"""エイシング プログラミング コンテスト 2020: B - An Odd Problem
https://atcoder.jp/contests/aising2020/tasks/aising2020_b
"""


def main():
    N = int(input())
    As = list(map(int, input().split()))

    ans = 0
    for i in range(N):
        if (i + 1) % 2 != 0 and As[i] % 2 != 0:
            ans += 1
    print('{}'.format(ans))


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N=int(input())
a=list(map(int,input().split(' ')))
n=0
for i in range(0,N,2):
  if a[i]%2==1:
    n+=1

print(n)

Submission status: Accepted

Solution code:
import math
from collections import *
import sys
inp=sys.stdin.readline

def linp(x):
    return list(map(int,x.split()))
def minp(x):
    return map(int,x.split())
    
def main():
    n=int(inp())
    l =linp(inp())
    c=0
    for i in range(1,n+1):
        if i%2 == 1 and l[i-1]%2==1:
            c+=1
    print(c)



if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N = int(input())
a_list = list(map(int, input().split()))
count = 0
for item in a_list[::2]:
    if item % 2 == 1:
        count += 1

print(count)

Submission status: Accepted

Solution code:
N = int(input())
a_i = map(int, input().split())
count = 0

for idx, number in enumerate(a_i):
  if (idx + 1) % 2 != 0 and number % 2 != 0:
    count += 1

print(count)

Submission status: Accepted

Solution code:
def main():

    N = int(input())
    # L, R, d = map(int, input().split())
    A = [int(i) for i in input().split()]
    ans = 0
    for v in A[0::2]:
        if v % 2 == 1:
            ans += 1

    print(ans)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int,input().split()))
ans = 0
for i in range(N):
  if (i % 2 == 0) and (a[i] % 2 == 1):
    ans +=1
print(ans)

Submission status: Accepted

Solution code:
n=int(input())
A=list(map(int,input().split()))
x=0
for i in range(0,n,2):
  if A[i]%2==1:
    x+=1
print(x)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int,input().split()))
ans=0
for i in range(1,1+N):
  if (i % 2 != 0) and (a[i-1] % 2 != 0):
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
n=int(input())
lst=list(map(int,input().split()))
ans=0
for i in range(0,n):
 if (i+1)%2==0:
    pass
 elif lst[i]%2!=0:
    ans+=1
 else:
  pass
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
l = map(int, input().split())
res=0
for i, v in enumerate(l):
    if v % 2 == 1 and (i + 1) % 2 == 1:
        res += 1
        
print(res)

Submission status: Accepted

Solution code:
N = int(input())
As = list(map(int, input().split()))


def isOdd(i):
    if i % 2 == 0:
        return False
    else:
        return True

i = 1
ans = 0
for a in As:
    if isOdd(a) and isOdd(i):
        ans = ans + 1

    i = i + 1

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
lista = list(map(int, input().split()))
n = 1
cou = 0
while n<=N:
    if n%2==1:
        if lista[n-1]%2==1:
            cou = cou+1
            n = n+1
        else:
            n = n+1
    else:
        n = n+1
print(cou)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))

cnt = 0
for i in range(N):
    if (i%2 == 0 and a[i]%2 == 1):
        cnt += 1
    
print(cnt)

Submission status: Accepted

Solution code:
# Coding is about expressing your feeling, and
# there is always a better way to express your feeling_feelme
import sys
import math
# sys.stdin=open('input.txt','r')
# sys.stdout=open('output2.txt','w')
from sys import stdin,stdout
from collections import deque,defaultdict
from math import ceil,floor,inf,sqrt,factorial,gcd,log2
from copy import deepcopy
ii1=lambda:int(stdin.readline().strip())
is1=lambda:stdin.readline().strip()
iia=lambda:list(map(int,stdin.readline().strip().split()))
isa=lambda:stdin.readline().strip().split()
mod=int(1e9 + 7)

n=ii1()
arr=iia()
count=0
for i in range(n):
    if (i+1)%2==1:
        if arr[i]%2==1:
            count+=1
print(count)

Submission status: Accepted

Solution code:
n=int(input())
aa=list(map(int,input().split()))
count=0
for i in range(n):
  if (i+1)%2==1 and aa[i]%2==1:
    count+=1
print(count)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))

ans = 0

for i in range(0,N,2):
    if a[i]%2==1:
        ans+=1
print(ans)

Submission status: Accepted

Solution code:
import math
import itertools
import numpy as np

t = int(input())
a=list(map(int, input().split()))
num = 0
for i in range(t):
    if i%2 == 0 and a[i]%2 == 1:
        num+=1
print(num)

Submission status: Accepted

Solution code:
N = int(input())
lis = list(map(int, input().split()))
count = 0

for i in range(N):
    if (i+1) % 2 == 1 and lis[i] % 2 == 1:
       count += 1

print(count)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int,input().split()))
c = sum(a[x]%2 for x in range(0,n,2))
print(c)

Submission status: Accepted

Solution code:

N=int(input())
a=list(map(int, input().split()))
ans = 0
for i in range(1, N+1, 1):
    if i % 2 != 0:
        if a[i-1] % 2 != 0:
            ans += 1

print(ans)

Submission status: Accepted

Solution code:
def main():
    n = int(input())
    a = list(map(int, input().split()))
    count = 0
    for i in range(n):
        if i % 2 ==0 and a[i]% 2== 1:
            count += 1
    print(count)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
x = int(input())
c = [i for i in range(1,x+1)]
l = map(int,input().split())
count = 0
for i,j in zip(c,l):
	if i% 2== 1 and j%2 == 1:
		count+=1
print(count)

Submission status: Accepted

Solution code:
n = (int)(input())
a=list(map(int, input().split(" ")))
count = 0

for i in range(0, n, 2):
  if a[i] % 2 == 1:
    
    count += 1
print(count)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))
cnt = 0
for i in range(n):
    if (i + 1) % 2 != 0:
        if a[i] % 2 != 0:
             cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split(' ')))

ans = 0
for i in range(0,N,2):
    if a[i] % 2 == 1:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int,input().split()))

ans = 0
for i in range(0,N,2):
    if a[i]%2==1:
        ans+=1

print(ans)

Submission status: Accepted

Solution code:
total = int(input())
num_list = list(map(int, input().split()))
result = 0

for i in range(total):
  if i % 2 == 0:
    if num_list[i] % 2 == 1:
      result += 1

print(result)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

n = int(input())
l = input().split(' ')

s = 0
for i in range(n):
    if i % 2 == 0 and int(l[i]) % 2 == 1:
        s += 1

print(s)

Submission status: Accepted

Solution code:
N = int(input())
x = list(map(int, input().split()))

a = []
for i in range(N):
  if (i+1) % 2 and x[i] % 2:
    a.append(x[i])
print(len(a))

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))
b = a[::2]
ans = 0
for i in range(len(b)):
  if b[i]%2 == 1:
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())

A_list = list(map(int, input().split()))

import numpy as np

A_array = np.array(A_list)

A_odd = A_array % 2 == 1

print(np.sum(A_odd[list(range(0,N,2))]))

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))
count=0
for i in a[0::2]:
  if i % 2 != 0:
    count += 1


print(count)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))

la = a[::2]
ans = 0

for i in la:
    if i%2 == 1:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
def main():
    n = int(input())
    a = list(map(int, input().split()))

    cnt = 0
    for i, e in enumerate(a):
        if (i+1) % 2 == 1 and e % 2 == 1:
            cnt += 1

    print(cnt)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N=int(input())
A=list(map(int,input().split()))
ans=0

for i in range(N):
    if (i+1) % 2==1 and A[i] %2 ==1:
        ans+=1
print(ans)

Submission status: Accepted

Solution code:
n = int(input())
count = 0
arr = [int(i) for i in input().split()]
for i in range(1,n+1):
    if i % 2 == 1 and arr[i-1] % 2 == 1:
        count += 1
print(count)

Submission status: Accepted

Solution code:
N = int(input())
LIST = list(map(int, input().split()))
count = 0
for i in range(0,len(LIST),2):
    try:
        if LIST[i] % 2 != 0:
            count += 1
    except:
        pass
print(count)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
A.insert(0, 0)
ans = 0
for i in range(1, N + 1, 2):
    if A[i] % 2 == 1:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
N=int(input())

a=list(map(int,input().split()))
count=0
for i in range(N):
    if ((i+1%2)&(a[i]%2)):
        count+=1
print(count)

Submission status: Accepted

Solution code:

n = int(input())

a = list(map(int,input().split()))

ans = 0

for i, a in enumerate(a):
    if (i + 1) % 2 == 1:
        if a % 2 == 1:
            ans += 1

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
arr = list(map(int, input().split()))
count = 0
for i in range(1, N+1):
  if (i%2 == 1) and (arr[i-1]%2 == 1):
    count += 1
print(count)

Submission status: Accepted

Solution code:
N = int(input())

ans = 0

Line = [int(s) for s in input().split()]

for i,x in enumerate(Line):
    if i % 2 == 0:
        # print(i,x)
        if x % 2 == 1:
            ans += 1

print(ans)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))

cnt = 0
for num, val in enumerate(a):
    if (num + 1) % 2 == 1 and val % 2 == 1:
        cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
import sys,collections as cl,bisect as bs
sys.setrecursionlimit(100000)
input = sys.stdin.readline
mod = 10**9+7
Max = sys.maxsize
def l(): #intのlist
	return list(map(int,input().split()))
def m(): #複数文字
	return map(int,input().split())
def onem(): #Nとかの取得
	return int(input())
def s(x): #圧縮
	a = []
	if len(x) == 0:
		return []
	aa = x[0]
	su = 1
	for i in range(len(x)-1):
		if aa != x[i+1]:
			a.append([aa,su])
			aa = x[i+1]
			su = 1
		else:
			su += 1
	a.append([aa,su])
	return a
def jo(x): #listをスペースごとに分ける
	return " ".join(map(str,x))
def max2(x): #他のときもどうように作成可能
	return max(map(max,x))
def In(x,a): #aがリスト(sorted)
    k = bs.bisect_left(a,x)
    if k != len(a) and a[k] ==  x:
        return True
    else:
        return False

def pow_k(x, n):
    ans = 1
    while n:
        if n % 2:
            ans *= x
        x *= x
        n >>= 1
    return ans

"""
def nibu(x,n,r):
	ll = 0
	rr = r
	while True:
		mid = (ll+rr)//2

	if rr == mid:
		return ll
	if (ここに評価入れる):
		rr = mid
	else:
		ll = mid+1
"""

n = onem()

a = l()

ans = 0

for i in range(n):
	if i % 2 == 0:
		if a[i] % 2 != 0:
			ans += 1
print(ans)

Submission status: Accepted

Solution code:
def main():
    n=int(input())
    a=list(map(int,input().split()))
    cnt=0
    for i in range(n):
        if (i+1)%2==0: continue
        if a[i]%2==0: continue
        cnt+=1
    print(cnt)
    return

if __name__=='__main__':
    main()

Submission status: Accepted

Solution code:
n = int(input())
m = list(map(int,input().split()))
count = 0
for i in range(n):
    if (i+1)%2==1:
        if m[i]%2==1:
            count+=1
print(count)

Submission status: Accepted

Solution code:
N = int(input())
a=list(map(int,input().split()))
c = 0
for i in range(N):
  if i%2==0:
    if a[i]%2==1:
      c = c+1
print(c)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))

ans = 0
index = 1

for i in a:
    if index % 2 == 1 and i % 2 == 1:
        ans += 1
    index += 1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
count = 0

for i, a in enumerate(A):
    if (i + 1) % 2 == 1 and a % 2 == 1:
        count += 1

print(count)

Submission status: Accepted

Solution code:
n=int(input())
a=list(map(int,input().split()))
p=0
for i in range(n):
  if((i%2==0)and(a[i]%2==1)):
    p+=1
print(p)

Submission status: Accepted

Solution code:
N = int(input())
a = list(map(int, input().split()))
i = 0
count = 0
for i,ai in enumerate(a):
    if((i+1)%2==1)and(ai%2==1):
        count+=1
print(count)

Submission status: Accepted

Solution code:
n = int(input())
A = list(map(int, input().split()))
cnt = 0
index = 1
for i in A:
    if index%2 != 0 and i%2 != 0:
        cnt += 1
    index += 1
print(cnt)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
 
ans = 0
for i in range(1, N + 1):
#    print(i)
    if A[i-1] % 2 == 1 and i % 2 == 1:
        ans += 1
 
print(ans)

Submission status: Accepted

Solution code:
n=int(input())
a=list(map(int,input().split()))
count=0
for i in range(0,n,2):
  if a[i]%2!=0:
    count+=1
print(count)

Submission status: Accepted

Solution code:
n = int(input())
l = [int(s) for s in input().split()]

ans = 0
for x in range(n):
  if x % 2 == 0 and l[x] % 2 == 1:
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
N=int(input())
a=list(map(int,input().split()))
 
ans=0
for i in range(0,N,2):
    if a[i]%2!=0:
        ans+=1
        
print(ans)