Java program to remove the elements which appear more than k times from the array .
import java . util . HashMap ; import java . util . Map ; class GFG { static void RemoveElements ( int arr [ ] , int n , int k ) {