Answer:
See explaination for code
Step-by-step explanation:
int x, y;
ifstream numbers;
numbers.open ("numbers.txt");
ofstream min;
min.open ("min.txt");
ofstream max;
max.open ("max.txt");
while(numbers>>x>>y )
{
if(x>y)
{
max<<x<<endl;
min<<y<<endl;
}
else
{
max<<y<<endl;
min<<x<<endl;
}
}
numbers.close;
min.close;
max.close;