Răspuns:
#include <iostream>
#include <fstream>
using namespace std;
ifstream fin("pozmax.in");
ofstream fout("pozmax.out");
int main()
{
unsigned n;
fin>>n;
float x,Max=0,p,u;
for(unsigned i=1;i<=n;i++)
{fin>>x;
if(x>Max)
{
Max=x;
p=i;
}
if(x==Max)
{
u=i;
}
}
fout<<p<<' '<<u;
}