Complete the method below. // returns true if the array heap…

Complete the method below. // returns true if the array heapData represents a proper min-heap, false otherwise.// assume that heapData is an array of String with the index 0 representing the root. // write an iterative method, do not use recursionpublic boolean isMinHeap(String [] heapData, int size){