// main1.cc    Main driver to test function to find index of max element
// P. Conrad, 01/28/2007

#include <iostream>
using namespace std;


// function prototypes for separately compiled functions

int indexOfLargestElement(int a[], int size);

int main()
{

  cout << "Testing a function to find largest element\n";


  // test the indexOfLargestElement function on two different arrays
  // print the result from both tests

  int a[]={3, 2, 5, 4, 1, 0};
  
  int result1;
  result1 = indexOfLargestElement(a,6);
  cout << "result1 = " << result1 << endl;


  int b[]={6,2,4,9,1,5,7};
  
  int result2;
  result2 = indexOfLargestElement(b,7);
  cout << "result2 = " << result2 << endl;


  return 0; // normal successful completion


}

