Given the following function definition, what modifications need to be made to the search function so that it finds all occurrences of target in the array?int search(const int array[], int target, int numElements){int index=0;bool found=false;while((!found) && (index < numElements)){if(array[index] == target)found=true;elseindex++;}if(found==true)return index;elsereturn -1;}a. Add another parameter to indicate where to stop searchingb. Add another parameter to indicate where to start searchingc. This already can find all occurrences of a given targetd. Have the function return the whole array