Computer Science, asked by redits2121, 3 days ago

7. Write a program to input an array of size N. Replace all the positive values in the array to 0 and print the array​

Answers

Answered by rishab1247832
0

Answer:

I don't kow

realy i dont know

Answered by RKRUHIRK
2

Answer:

Given an array of size n, find all elements in array that appear more than n/k times. For example, if the input arrays is {3, 1, 2, 2, 1, 2, 3, 3} and k is 4, then the output should be [2, 3]. Note that size of array is 8 (or n = 8), so we need to find all elements that appear more than 2 (or 8/4) times. There are two elements that appear more than two times, 2 and 3. 

Similar questions