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

print(cnt)

Submission status: Accepted

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

Submission status: Accepted

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

cnt=0
n=1
for i in lis:
    if i%2 != 0 and n%2 != 0:
        cnt += 1
    n += 1
print(cnt)

Submission status: Accepted

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

for x in range(0, len(a)):
    if (x + 1) % 2 == 1 and a[x] % 2 == 1:
        count += 1
print(count)

Submission status: Accepted

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

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

print(num)

Submission status: Accepted

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

Submission status: Accepted

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

import sys
import math


debug = False

def log(text):
    if debug:
        print(text)

def parse_input(lines_as_string = None):

    global debug
    lines = []
    if lines_as_string is None:
        debug = False
        for line in sys.stdin:
            lines.append(line.strip())
    else:
        debug = True
        lines = [e for e in lines_as_string.split("\n")][1:-1]

    n = int(lines[0])
    aa = [int(e) for e in lines[1].split(' ')]

    return (n, aa)


def solve(n, aa):

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


def main():
    # 出力
    result = solve(*parse_input())
    if isinstance(result, list):
        for r in result:
            print("%s" % r, sep='')
    else:
        print("%s" % result, sep='')

if __name__ == '__main__':

    main()

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:
N = int(input())
M = list(map(int, input().split(' ')))

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

print(count)

Submission status: Accepted

Solution code:
from sys import stdin,stdout
def INPUT():return list(int(i) for i in stdin.readline().split())
def inp():return stdin.readline()
def out(x):return stdout.write(x)
import math
#=================================================
n=int(input())
A=INPUT()
count=0
for i in range(0,n,2):
    if (i+1)%2==1 and A[i]%2==1:
        count+=1
print(count)

Submission status: Accepted

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

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

print(count)

Submission status: Accepted

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

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

Submission status: Accepted

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

import sys

def main():
    input = sys.stdin.readline
    n = int(input())
    a_list = list(map(int, input().split()))

    result = 0
    for i, a in enumerate(a_list):
        if i % 2 == 0:
            if  not a % 2 == 0:
                result += 1
        else:
            continue

    print(result)

    return


if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
import  math
import fractions
from collections import defaultdict
stdin = sys.stdin
     
ns = lambda: stdin.readline().rstrip()
ni = lambda: int(stdin.readline().rstrip())
nm = lambda: map(int, stdin.readline().split())
nl = lambda: list(map(int, stdin.readline().split()))

N=int(input())
A=nl()

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

print(ans)

Submission status: Accepted

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

hoge = 0

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

print(hoge)

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()))

counter = 0
for i in range(N):
    checker_1 = (i + 1) % 2 == 1
    checker_2 = A[i] % 2 == 1
    if checker_1 & checker_2:
        counter += 1
print(counter)

Submission status: Accepted

Solution code:

N = int(input())
a_vec = [int(digit) for digit in input().split()]
a_odd_vec = a_vec[::2]

c = 0
for e in a_odd_vec:
    if e % 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()))

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

print(count)

Submission status: Accepted

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

count = 0
length = len(given_list)

for _ in range(length):
  if ((_ + 1) % 2 != 0) and (given_list[_] % 2 != 0):
    count += 1

print(count)

Submission status: Accepted

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

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

print(ans)

Submission status: Accepted

Solution code:
import sys
import numpy as np

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

o = 0
for i, ai in enumerate(a):
    if ai % 2 != 0 and i % 2 == 0:
        o += 1

print(o)

Submission status: Accepted

Solution code:
##a = int(stdin.readline().rstrip())
##b, c = [int(x) for x in stdin.readline().rstrip().split()]
##s = stdin.readline().rstrip()
##a = list(set(b))  重複を削除
##a = list(map(int,[int(x) for x in stdin.readline().rstrip().split()])) a[0, 1, 2, ...]
##a = [[0] * 2 for _ in range(n)]  a[0,0]
##v = [s[i: i+2] for i in range(0, len(s), 2)]
##  s="12345678" を v=["12","34","56","78"] にするイメージ
##s = "".join(list)リストを文字列に変換[""]は区切り文字
##a.sort(key=itemgetter(1))リストをソートできるよ(from operator import itemgetterが必要)
##sort_p = sorted(p) 昇順ソート

# -*- coding: utf-8 -*-
from sys import stdin
from operator import itemgetter
from collections import deque, Counter
import math
import pprint
from functools import reduce
import numpy as np
import random
import bisect
import copy
# stdin = open("sample.txt")


MOD = 1000000007
INF = float('inf')
alpha = ["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]

def keta(kazu): # 入力されたintを桁ごとに分解，リストで出力
    kazu_str = str(kazu)
    kazu_list = [int(kazu_str[i]) for i in range(0, len(kazu_str))]
    return kazu_list

def gcd(*numbers): # 最小公倍数
    return reduce(math.gcd, numbers)

def combination(m,n): # mCn
    
    if n > m:
        return 'すまん'
    return math.factorial(m) // (math.factorial(m-n) * math.factorial(n))

def pow_k(x,n):  # (x**n)の計算の高速化
    if n == 0:
        return 1
    K = 1
    while n > 1:
        if n % 2 != 0:
            K *= x
        x *= x
        n //= 2
    return K * x

def fact(n): # nの素因数分解の結果を辞書で出力 fuct(24) → {2: 3, 3: 1}
    arr = {}
    temp = n
    for i in range(2,int(n**0.5)+1):
        if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr[i] = cnt
    if temp != 1:
        arr[temp] = 1
    if arr == {}:
        arr[n] = 1
    return arr


    
def main():
    n = int(stdin.readline().rstrip())
    a = list(map(int,[int(x) for x in stdin.readline().rstrip().split()]))
    ans = 0
    for i in range(n):
        if (i+1) % 2 == 1 and a[i] % 2 == 1:
            ans += 1
    print(ans)
main()

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 sys
import numpy as np
# from decimal import Decimal
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

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

arr = np.array(a)
a1 = np.where(arr % 2 != 0)

#print(a1)
a2 = a1[0] + 1
a3 = np.where(a2 % 2 != 0)
#print(a3)
print(len(a3[0]))

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()))
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())
arr = [int(x) for x in input().split()]
count = 0
for i in range(n):
    if i%2 == 0 and arr[i]%2:
        count += 1
print(count)

Submission status: Accepted

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

print(ans)

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

print(num)

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) and (a[i] % 2 != 0):
		#print("i,a[i]",i,a[i])
		cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
def main():
    N = int(input())
    A = list(map(int, input().split()))
    cnt = 0
    for i in range(1, N+1, 2):
        if A[i-1] % 2 == 1:
            cnt += 1
    print(cnt)

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def main():
    n = int(input())
    ai = map(int, input().split(' '))
    count = 0

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

if __name__ == '__main__':
    main()

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
from collections import Counter,defaultdict,deque
from heapq import heappop,heappush
from bisect import bisect_left,bisect_right 
import sys,math,itertools,fractions,pprint
sys.setrecursionlimit(10**8)
mod = 10**9+7
INF = float('inf')
def inp(): return int(sys.stdin.readline())
def inpl(): return list(map(int, sys.stdin.readline().split()))

n = inp()
a = inpl()
res = 0
for i,x in enumerate(a):
    if i%2==0 and x%2:
        res += 1
print(res)

Submission status: Accepted

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

main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
from sys import stdin


def readline_from_stdin() -> str:
    return stdin.readline().rstrip


if __name__ == '__main__':
    N = int(input())
    A = input().split()
    a = [int(v) for _, v in enumerate(A)]
    print(len([v for i, v in enumerate(a) if (i+1) % 2 != 0 and v % 2 != 0]))

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int,input().split()))
index = list(range(1,n+1))

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
'''
5
1 3 4 5 7
'''
lens = int(input())
vals = [0] + [int(x) for x in input().split()]
odds = 0
for i in range(1, lens + 1):
    if i % 2 == 1 and vals[i] % 2 == 1:
        odds += 1
print(odds)

Submission status: Accepted

Solution code:
import sys


if(__name__ == "__main__"):

    N = int(input().strip())

    AStr = input().strip().split()
    AList = [0] * N
    for i in range(N):
        AList[i] = int(AStr[i])

    N_odd = 0
    for i in range(0, N, 2):
        if(AList[i]%2!=0):
            N_odd+=1
    print(N_odd)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

print(len(num))

Submission status: Accepted

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

count = 0
for i, v in enumerate(a):
    index = i + 1
    if index % 2 != 0 and v % 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(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())
l = list(map(int, input().split()))
result = 0
for i in range(len(l)):
    num_1 =  i + 1
    num_2 = l[i]
    
    if  (num_1 * num_2)  % 2 != 0:
        result += 1
print(result)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

s = 0

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

print(s)

Submission status: Accepted

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

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())
ans = 0
a = list(map(int, input().split()))

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
n = int(input())
num = list(map(int,input().split()))
indexs = list(range(1,n+1))
count = 0

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

Submission status: Accepted

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

answer = 0
for i in range(N):
    if (i+1) % 2 == 1:
        if L[i] % 2 == 1:
            answer = answer + 1

print(answer)

Submission status: Accepted

Solution code:
import sys
N = int(input())
a = list(map(int, sys.stdin.readline().strip().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 sys
import numpy as np
import math
import collections
import copy
from collections import deque 
from functools import reduce
from itertools import product

# input = sys.stdin.readline

N = int(input())
ai = list(map(int, input().split()))
cnt = 0
for i, a in enumerate(ai):
    if (i+1) % 2 == 1 and a % 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 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, b in enumerate(a):
  if (i + 1) % 2 == 1 and b % 2 == 1:
      cnt += 1

print(cnt)

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, v in enumerate(a):
    if (i + 1) % 2 != 0 and v % 2 != 0:
        ans += 1

print(ans)

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

Submission status: Accepted

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

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

print(ans)

Submission status: Accepted

Solution code:
import sys

n, *aaa = map(int, sys.stdin.buffer.read().split())
ans = 0
for i, a in enumerate(aaa, start=1):
    if i % 2 == 1 and a % 2 == 1:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
import sys

n = int(sys.stdin.readline())
a = list(map(int, sys.stdin.readline().split()))
cnt = 0
for i, item in enumerate(a):
    if (i+1)*item % 2 == 1:
        cnt += 1
print(cnt)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N=int(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

        ans +=1
    num +=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)):
    if (i + 1) % 2 == 1 and A[i] % 2 == 1:
        count += 1

print(count)

Submission status: Accepted

Solution code:
"""
    こんにちは。これはクシャルです
    
    Author : thekushalghosh (クシャル)
    Team   : CodeDiggers
 
    I prefer Python language over the C++ language :p :D
        
    Visit my website : thekushalghosh.github.io
"""
import sys,math,cmath,time,itertools
start_time = time.time()
##########################################################################
################# ---- THE ACTUAL CODE STARTS BELOW ---- #################

def solve():
    n = inp()
    a = inlt()
    c = 0
    for i in range(n):
        if i % 2 == 0 and a[i] % 2 != 0:
            c = c + 1
    print(c)
    
################## ---- THE ACTUAL CODE ENDS ABOVE ---- ##################
##########################################################################
 
def main():
    global tt
    if not ONLINE_JUDGE:
        sys.stdin = open("input.txt","r")
        sys.stdout = open("output.txt","w")
    t = 1
    for tt in range(t):
        solve()
    if not ONLINE_JUDGE:
        print("Time Elapsed :",time.time() - start_time,"seconds")
        sys.stdout.close()
    
#---------------------- USER DEFINED INPUT FUNCTIONS ----------------------#
def inp():
    return(int(input()))
def inlt():
    return(list(map(int,input().split())))
def insr():
    return(input().strip())
def invr():
    return(map(int,input().split()))
 
#------------------ USER DEFINED PROGRAMMING FUNCTIONS ------------------#
def counter(a):
    q = [0] * max(a)
    for i in range(len(a)):
        q[a[i] - 1] = q[a[i] - 1] + 1
    return(q)

def counter_elements(a):
    q = dict()
    for i in range(len(a)):
        if a[i] not in q:
            q[a[i]] = 0
        q[a[i]] = q[a[i]] + 1
    return(q)

def string_counter(a):
    q = [0] * 26
    for i in range(len(a)):
        q[ord(a[i]) - 97] = q[ord(a[i]) - 97],1
    return(q)
 
def factors(n):
    q = []
    for i in range(1,int(n ** 0.5) + 1):
        if n % i == 0: q.append(i); q.append(n // i)
    return(list(sorted(list(set(q)))))
 
def prime_factors(n):
    q = []
    while n % 2 == 0: q.append(2); n = n // 2
    for i in range(3,int(n ** 0.5) + 1,2):
        while n % i == 0: q.append(i); n = n // i
    if n > 2: q.append(n)
    return(list(sorted(q)))

def transpose(a):
    n,m = len(a),len(a[0])
    b = [[0] * n for i in range(m)]
    for i in range(m): 
        for j in range(n): 
            b[i][j] = a[j][i]
    return(b)

#-----------------------------------------------------------------------#
        
ONLINE_JUDGE = __debug__
if ONLINE_JUDGE:
    input = sys.stdin.readline
    
    
main()

Submission status: Accepted

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

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

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:
import sys
n=int(input())
l = list(map(int,input().split()))
m=int(n/2)
ans=0
if n%2==1:
    for i in range(m+1):
        if l[i*2]%2==1:
            ans+=1
    print(ans)
    sys.exit()
else:
    for i in range(m):
        if l[i*2]%2==1:
            ans+=1
    print(ans)

Submission status: Accepted

Solution code:
import collections
import sys
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()))
count = 0
for i in range(N):
  if i % 2 == 0 and A[i] % 2 == 1:
    count += 1
print(count)

Submission status: Accepted

Solution code:
import sys

if __name__ == "__main__":
    N = int(sys.stdin.readline())
    A = list(map(lambda x: int(x), sys.stdin.readline().split()))
    
    ans = 0
    for i, a in enumerate(A):
        if i%2==0 and a % 2 == 1:
            ans += 1
        
    print(ans)

Submission status: Accepted

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

Submission status: Accepted

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