Company: Autodesk SDE intern on campus_9april
Difficulty: easy
Odd Occurrences of Digit Zero You are given an array a of n non-negative integers. An element counts when the digit 0 appears an odd number of times in its ordinary decimal spelling (written without leading zeros). An element in which the digit 0 never appears does not count, because zero occurrences is an even number. Report how many elements of a count. For example, in [4, 50, 100, 65, 2000, 700, 1, 10] three elements count: 50 and 10 each spell one zero, and 2000 spells three. 100 and 700 each spell two zeros, which is even, and 4 , 65 and 1 spell none. The value 0 is spelled 0 , so it contains the digit 0 exactly once — an odd number of times — and it counts. Input Format The first line contains one integer n , the length of the array. The second line contains n space-separated non-negative integers a[0], a[1], ..., a[n-1] . The first line is the length only. It is not an element of the array and must never be examined. Output Format Print a single integer: the number of elements o