Count Even and Odd Problem
Count Even and Odd Problem — ExecCode School DSA Practice
Solve the Count Even and Odd problem on ExecCode. Free online school DSA practice in Arrays - Basics. Write and run code in Java, C++, Python — no signup required to run.
Problem description
Given an array of integers, count the total number of even numbers and the total number of odd numbers. Your task is to solve Count Even and Odd. Print these two counts.
Examples
Input 5 1 2 3 4 5; Output 2 3. Input 3 2 4 6; Output 3 0
Constraints
1 <= N <= 10^4
Practice Count Even and Odd free on ExecCode. Browse DSA problems, topic map, and placement guides.