#include<iostream>
#include<string.h>
using namespace std;
int main(){
int age[10];
string name[10];
int max;
int min;
for(int i=0;i<10;i++){ // taking input
cout<<"Enter Name: ";
cin>>name[i];
cout<<"Enter age: ";
cin>>age[i];
if(i==0){
max=i;
min=i;
}else{ // for comparing the max and min
if(age[max]<age[i]){ // if current max is less than entered max
update
max=i;
}
if(age[min]>age[i]){ // if current min is greater than entered
update min
min=i;
}
}
}
cout<<"Youngest person: "<<endl;
cout<<"name: "<<name[min]<<endl;
cout<<"age: "<<age[min]<<endl;
cout<<"Oldest person: "<<endl;
cout<<"name: "<<name[max]<<endl;
cout<<"age: "<<age[max]<<endl;
return 0;
}
Write a C++ program which will prompt the user to enter the name and age of...