I am trying to write a simple logical program to find the highest and lowest values, which has already been done. The issue is how to find the index position is when it finds the highest and lowest value. See the attached picture.

#include <iostream>
using namespace std;
int main()
{
int number=0, min=0, max=0;
int *rangeOfNumbers = new int[];
cout<<"Enter 5 numbers: ";
for(int i=0; i<5;i++)
{
cout<<"Enter number "<<i+1<<": ";
cin>>rangeOfNumbers[i];
}
//max min array positions
min=rangeOfNumbers[0];
max=rangeOfNumbers[0];
//find max and mins
for(int j=0; j<5;j++)
{
if(max<rangeOfNumbers[j])
{
max=rangeOfNumbers[j];
}
else if(min>rangeOfNumbers[j])
{
min=rangeOfNumbers[j];
}
}
cout<<"\n\nMin number: "<<min;
cout<<"\nMax number: "<<max;
cin.get();
cin.get();
return 0;
}