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=[0]+list(map(int,input().split()))
cnt=0
for i in range(1,n+1):
    if i%2==0:
        continue
    else:
        if a[i]%2==1:
            cnt+=1
print(cnt)

Submission status: Accepted

Solution code:
mod = 1000000007
eps = 10**-9


def main():
    import sys
    input = sys.stdin.readline

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


if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding: utf-8

import math
import re
import numpy as np
import copy

#読み込む
N = int(input())
an = list(map(int, input().split(' ')))
ans = 0

for i in range(N):
    if (i+1) % 2 == 0:
        continue
    elif an[i] % 2 != 0:
        ans += 1

print(ans)

Submission status: Accepted

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


ans = []
for i in range(n):
    if i%2==0 and a[i]%2==1:
        ans.append(i)
print(len(ans))

Submission status: Accepted

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

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:
import sys
import numpy as np

# 実行環境(0:vscode, 1:atcoder)
MODE = 1

# 入力の次元
DIMENSION = 2

# int型に変換
INT_TYPE = 1

if not (MODE):
    with open("input.txt", "r") as f:
        s = f.read()
else:
    s = sys.stdin.read()

if DIMENSION == 0:
    if INT_TYPE == 1:
        s = int(s)
elif DIMENSION == 1:
    if INT_TYPE == 0:
        s = s.split()
    elif INT_TYPE == 1:
        s = [int(x) for x in s.split()]
elif DIMENSION == 2:
    if INT_TYPE == 0:
        s = [x.split() for x in s.splitlines()]
    elif INT_TYPE == 1:
        s = [[int(y) for y in x.split()] for x in s.splitlines()]

N = s[0][0]
a = s[1]

cnt = 0
for i in range(0, N, 2):
    if a[i] % 2 == 1:
        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+1) % 2 == 1 & A[i] % 2 == 1:
    ans += 1
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N= int(input())

A = list(map(int, input().strip().split()))
count=0
for i in range(N):
    if i%2==0:
        if A[i]%2!=0:
            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+1)%2==1 and a[i]%2==1:
        c+=1
print(c)

Submission status: Accepted

Solution code:
n=int(input())
a=[int(i) for i in input().split()]
ans=chk=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()))
count = 0
for i in range(len(a)):
     j = i + 1
     if j % 2 == 0:
         continue
     if a[i] % 2 == 0:
         continue
     count += 1

print(count)

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 % 2 == 0:
            if a[i] % 2 == 1:
                cnt += 1

    print(cnt)



if __name__ == '__main__':
    main()

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 and A[i]%2==1:
    c+=1
print(c)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# 幅優先探索（行きがけ）
import collections
import sys


def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int, sys.stdin.readline().rstrip().split()))
def S(): return sys.stdin.readline().rstrip()
def LS(): return list(sys.stdin.readline().rstrip().split())


def main():
    N = I()
    Aarray = LI()
    cnt = 0
    for i in range(N):
        if i % 2 == 0 and Aarray[i] % 2 != 0:
            cnt += 1
    print(cnt)


if __name__ == '__main__':
    main()

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:
        if A[i] % 2 != 0:
            cnt += 1
    else:
        continue    
print(cnt)

Submission status: Accepted

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


def main():
  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)


if(__name__ == '__main__'):
  main()

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
n = int(input())
a = [int(i) for i in input().split()]
c=0
cc=0
for i in a:
  c+=1
  if c%2==0:
    continue
  if i%2!=0:
    cc+=1
print(cc)

Submission status: Accepted

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

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

count = 0
for i,v in enumerate(a):
     # print(i+1,v)
     if (i+1)%2 == 1 and v%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):
    if ((i + 1) % 2 == 1 and a[i] % 2 == 1):
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
def main(N, A):
    ans = 0
    for n in range(1, N+1, 2):
        if A[n-1] % 2 == 1:
            ans += 1
    print(ans)


if __name__ == '__main__':
    N = int(input())
    A = list(map(int, input().split()))
    main(N, A)

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) & (a[i]%2==1):
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
n, *a = map(int, open(0).read().split())
print(sum(a[i] % 2 > 0 for i in range(0, n, 2)))

Submission status: Accepted

Solution code:
def resolve():
    import sys
    input = sys.stdin.readline
    # 整数 1 つ
    n = int(input())
    # 整数複数個
    # a, b = map(int, input().split())
    # 整数 N 個 (改行区切り)
    # N = [int(input()) for i in range(N)]
    # 整数 N 個 (スペース区切り)
    A = list(map(int, input().split()))
    # 整数 (縦 H 横 W の行列)
    # A = [list(map(int, input().split())) for i in range(H)]

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

    print(cnt)


resolve()

Submission status: Accepted

Solution code:
import math
from collections import defaultdict

n = int(input())
a = list(map(int,input().split()))
c = 0
for i in range(n):
  if i&1:
    continue
  if a[i]&1:
    c += 1
print(c)

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!=0:
        ans+=1
print(ans)

Submission status: Accepted

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

ans = 0
for i in range(len(a)):
    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()))

#import numpy as np
ans=0
for ii in range(n):
  if (ii+1)%2==1 and a[ii]%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(n):
    if i%2==0 and a[i]%2==1:
        ans+=1
print(ans)

Submission status: Accepted

Solution code:
import bisect, collections, copy, heapq, itertools, math, string, sys
input = lambda: sys.stdin.readline().rstrip() 
sys.setrecursionlimit(10**7)
INF = float('inf')
def I(): return int(input())
def F(): return float(input())
def SS(): return input()
def LI(): return [int(x) for x in input().split()]
def LI_(): return [int(x)-1 for x in input().split()]
def LF(): return [float(x) for x in input().split()]
def LSS(): return input().split()

def resolve():
    N = I()
    a = LI()

    ans = len([a[i] for i in range(N) if i % 2 == 0 and a[i] % 2 != 0])
    print(ans)

if __name__ == '__main__':
    resolve()

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 += 1
print(count)

Submission status: Accepted

Solution code:
N = int(input())
nums = [int(i) for i in input().split()]

num = 0
for i in range(0,len(nums),2):
    if nums[i] % 2 != 0: num += 1
print(num)

Submission status: Accepted

Solution code:
import sys
from collections import deque
import numpy as np
import math
sys.setrecursionlimit(10**6)
def S(): return sys.stdin.readline().rstrip()
def SL(): return map(str,sys.stdin.readline().rstrip().split())
def I(): return int(sys.stdin.readline().rstrip())
def IL(): return map(int,sys.stdin.readline().rstrip().split())

def Main():
    n = I()
    a = list(IL())
    c = 0
    for rep in range(0,n,2):
        if a[rep]%2:
            c += 1
    print(c)
    return

if __name__=='__main__':
    Main()

Submission status: Accepted

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

ans = 0
for i, value in enumerate(a):
    if (i+1) % 2 == 1 and value % 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(N):
    if (i+1)%2==1:
        if 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 n1, i in enumerate(a):
    if n1 % 2 == 0:
        if i % 2 == 1:
            cnt += 1
print(cnt)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#from collections import deque,defaultdict
printn = lambda x: print(x,end='')
inn = lambda : int(input())
inl   = lambda: list(map(int, input().split()))
inm   = lambda:      map(int, input().split())
ins = lambda : input().strip()
DBG = True # and False
BIG = 10**18
R = 10**9 + 7
#R = 998244353

def ddprint(x):
  if DBG:
    print(x)

n = inn()
a = inl()
sm = 0
for i in range(n):
    if i%2==0 and a[i]%2>0:
        sm += 1
print(sm)

Submission status: Accepted

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

ans=0

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

print(ans)

Submission status: Accepted

Solution code:
def main():
  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)

if __name__ == "__main__":
  main()

Submission status: Accepted

Solution code:
import sys


def resolve():
    readline = sys.stdin.readline

    N = int(readline())
    a = [int(x) for x in readline().split()]
    ans = 0
    for i in range(N):
        if (i + 1) % 2 == 1 and a[i] % 2 == 1:
            ans += 1
    print(ans)
    

resolve()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

N = int(sys.stdin.readline().strip())
A = list(map(int, sys.stdin.readline().strip().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())
l=list(map(int,input().split()))
count=0
for i in range(n):
    if (i+1)%2==1 and l[i]%2==1:
        count+=1
print(count)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

input_methods=['clipboard','file','key']
using_method=0
input_method=input_methods[using_method]

tin=lambda : map(int, input().split())
lin=lambda : list(tin())
mod=1000000007

#+++++

def main():
	a = int(input())
	#b , c = tin()
	#s = input()
	al = lin()
	c=0
	for i, v in enumerate(al):
		if i % 2 == 0 and v % 2 == 1:
			c+=1
	print(c)
	
	
#+++++
isTest=False

def pa(v):
	if isTest:
		print(v)
		
def input_clipboard():
	import clipboard
	input_text=clipboard.get()
	input_l=input_text.splitlines()
	for l in input_l:
		yield l

if __name__ == "__main__":
	if sys.platform =='ios':
		if input_method==input_methods[0]:
			ic=input_clipboard()
			input = lambda : ic.__next__()
		elif input_method==input_methods[1]:
			sys.stdin=open('inputFile.txt')
		else:
			pass
		isTest=True
	else:
		pass
		#input = sys.stdin.readline
			
	ret = main()
	if ret is not None:
		print(ret)

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 != 0:
    if a[i] % 2 != 0:
      ans += 1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))[::2]
A = [a for a in A if a%2 != 0]
print(len(A))

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
def main():
    N = int(input())
    A = list(map(int, input().split()))
    ans = 0
    for i in range(N):
        if i%2 == 0:
            if A[i]%2 != 0:
                ans += 1
    print(ans)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import sys
sys.setrecursionlimit(10**6)


def main(input, print):
    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)


if __name__ == '__main__':
    main(sys.stdin.readline, print)

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

Submission status: Accepted

Solution code:
N = int(input())
A = [int(x) for x in input().split()]
count = 0
for i, a_i in enumerate(A):
    if (i + 1) % 2 == 1 and a_i % 2 == 1:
        count += 1

print(count)

Submission status: Accepted

Solution code:
n=int(input())
count=0
a = input().split(" ")
lista = [int(n) for n in a]
for i in range(0,n,2):
  if lista[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!=0:
    ans+=1
print(ans)

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
N = int(input())
A = [int(X) for X in input().split()]
Count = 0
for T in range(0,N):
    if (T+1)%2==1 and A[T]%2==1:
        Count += 1
print(Count)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = input()
arr = [int(x) for x in input().split()]

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
"""
NTC here
"""


#!/usr/bin/env python
import os
import sys
from io import BytesIO, IOBase

profile = 0
pypy = 1


def iin(): return int(input())


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



def main():
    T = 1
    while T:
        T -= 1
        n = iin()
        a = lin()
        ans = [1 for i in range(n) if a[i]%2 and i%2==0]
        print( sum(ans) if ans else 0)




    
        










    




                

        

 
 
 
 
 
 
# region fastio
 
BUFSIZE = 8192
 
 
class FastIO(IOBase):
    newlines = 0
 
    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None
 
    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()
 
    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()
 
    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)
 
 
class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")
 
if pypy:
    sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)
    input = lambda: sys.stdin.readline().rstrip("\r\n")
 
# endregion
 
if __name__ == "__main__":
    if profile:
        import cProfile
        cProfile.run('main()')
    else:
        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())
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())
a=list(map(int,input().split()))
m=0
for i in range(n):
  if ((i+1)/2!=(i+1)//2 and a[i]/2!=a[i]//2):
    m+=1
print(m)

Submission status: Accepted

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

ans = len([i for i, item in enumerate(a) if i%2==0 and item%2 ==1])
print(ans)

Submission status: Accepted

Solution code:
# Q2
import sys

def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def S(): return sys.stdin.readline().rstrip()
def LS(): return list(sys.stdin.readline().rstrip().split())

N = I()
a_list = LI()

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

Submission status: Accepted

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

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

  print(sum)

if __name__ == '__main__':
  main()

Submission status: Accepted

Solution code:
#B
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())
a_list = list(map(int, input().split()))

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

Submission status: Accepted

Solution code:
N = int(input())
nums = [int(i) for i in input().split()]

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

print(cnt)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())

cell = list(map(int,input().split()))
ans = 0
for i in range(N):
    if i % 2 == 0 and cell[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((N+1)//2):
  if a[2*i] % 2 == 1:
    ans += 1
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

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

print(num)

Submission status: Accepted

Solution code:
n = int(input())

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

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

print(ans)

Submission status: Accepted

Solution code:
import sys

def II(): return int(input())
def MI(): return map(int,input().split())
def LI(): return list(map(int,input().split()))
def TI(): return tuple(map(int,input().split()))
def RN(N): return [input().strip() for i in range(N)]


def main():
    N = II()
    a = LI()
    ans = 0


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

    
    print(ans)

if __name__ == "__main__":
	main()

Submission status: Accepted

Solution code:
N, *X = map(int, open(0).read().split())

ans = 0
for i in range(N):
    if (i + 1) % 2 == 1 and X[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(n):
    if i%2==0 and a[i]%2==1:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

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

ans = 0

for i, j in enumerate(a):
    if i % 2 == 0 and j % 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(n):
  if (i+1)%2==1 and a[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(1,n+1,2):
  if a[i-1] % 2 ==1:
    c+=1
    
print(c)

Submission status: Accepted

Solution code:
def main():
    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)
    return
if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n=int(input())
a=list(map(int, input().split()))
ans=0
for x in range(n):
    if x%2==0 and a[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(n):
    if (i+1)%2==1 and 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(N):
    if (i+1)%2 == 1 and 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(n):
    if a[i] % 2 == 1 and (i+1) % 2 == 1:
        ans += 1
print(ans)

Submission status: Accepted

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

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

print(ans)

Submission status: Accepted

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

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()))
b=a[::2]
cnt=0
for x in b:
        if x%2==1: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())
li = list(map(int,input().split()))

ans=0

for i in range(0,N,2):
    if li[int(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(N):
    if (i+1)%2 == 1 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, item in enumerate(a):
    if i % 2 == 0 and item % 2 == 1:
        cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

import sys

input = iter(sys.stdin.read().splitlines()).__next__


sys.setrecursionlimit(10000)

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

res = len([1  for i in range(N) if i % 2 == 0 and A[i] % 2 == 1 ])
print(res)

Submission status: Accepted

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

if n % 2 == 0:
    n = n - 1

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

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())
a = list(map(int,input().split()))
c = 0
for i in range(len(a)):
    if i % 2 == 0:
        if a[i]%2 == 1:
            c += 1
print(c)

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())
A = list(map(int, input().split()))
ans = 0
for i,v in enumerate(A):
    if i % 2 == 0 and v % 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(n):
    x = i+1
    if a[i]%2 == 1 and x%2 == 1:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
n = int(input())
a_list = [int(i) for i in input().split()]

c = 0
for i in range(len(a_list)) :
    if ((i+1) % 2 == 0) :
        continue

    if (a_list[i] % 2 == 1) :
        c += 1

print(c)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python
#pyrival orz
import os
import sys
from io import BytesIO, IOBase

"""
    for _ in range(int(input())):
    n,m=map(int,input().split())
    n=int(input())
    a = [int(x) for x in input().split()]
"""

def main():
    n=int(input())
    a = [int(x)%2 for x in input().split()]
    print(sum(a[::2]))

# region fastio

BUFSIZE = 8192


class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)


class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")


sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)
input = lambda: sys.stdin.readline().rstrip("\r\n")

# endregion

if __name__ == "__main__":
    main()

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:
input()
a = [int(i) for i in input().split()]

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

print(res)

Submission status: Accepted

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

print(res)