CT921

The Beryl stamps of Bram

EasyL2 · Byte BanditAcceptance: 0.0%XP: 10

The measurer Bram has been asked to inspect the delivered goods. On the desk lies a long table of stamps readings. Task: Read n integers and print how many are even. Input format: First line: n. Second line: n space-separated integers. Output format: Print the count of even values. Constraints: 1 <= n <= 28; -1000000 <= a[i] <= 1000000; answers fit a signed 64-bit integer.

Example 1:

Input: 7 197470 -684035 879860 -485206 -125315 -237812 -306278
Output: 5

Example 2:

Input: 5 570095 -780963 978203 916465 942516
Output: 1

Example 3:

Input: 9 -658973 -698061 638176 -149257 -474354 739488 -168239 761802 -553073
Output: 4

Constraints:

1 <= n <= 28; -1000000 <= a[i] <= 1000000; answers fit a signed 64-bit integer.

Loading...
Test Cases:No test cases
No test cases available.
The Beryl stamps of Bram - EASY Coding Problem | CodeTikki