Function to count frequency of each number in each subarray of length K
static void smallestPresentNumber ( int [ ] arr , int N , int K ) { Dictionary < int , int > mp = new Dictionary < int , int > ( ) ;