Help me in solving FIZZBUZZ2304 problem

My issue

I’m not able to solve this problem within the time limit. Please help!

My code

#include <stdio.h>


int countSubarrays(int arr[], int N, int K) {
    int oddCount = 0;

    for (int i = 0; i <= N - K; i++) {
        int bitwiseOR = 0;
        for (int j = i; j < i + K; j++) {
            bitwiseOR |= arr[j];
        }
        if (bitwiseOR % 2 != 0) {
            oddCount++;
        }
    }

    return oddCount;
}

int main() {
    int T;
    scanf("%d", &T);

    while (T--) {
        int N, K;
        scanf("%d %d", &N, &K);

        int A[N];
        for (int i = 0; i < N; i++) {
            scanf("%d", &A[i]);
        }

        int result = countSubarrays(A, N, K);
        printf("%d\n", result);
    }

    return 0;
}

Problem Link: FIZZBUZZ2304 Problem - CodeChef

@rishithareddy3
your logic will give u tle because of the high constraints.
Hint :- plzz observe that u will get bitwise or of the subarray as odd number if and only if there is at least one odd number in the subarray.