Given an array of N values. Print the number which has maximum number of zeroes. If there are no zeroes then print -1.
Note: If there are multiple numbers with same (max) number of zeroes then print the Maximum number among them.
The first line of input contains an integer T denoting the number of test cases. T testcases follow. Each testcase contains two lines of input. The first line consists of an integer N. The next line consists of N spaced integers.
For each testcase, print the number with maximum number of zeroes.
10 20 3000 9999 200
Testcase1: 3000 hsa maximum number of zeroes so we print it.
If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.