#include <iostream>
#include <string>
#include <fstream>
using namespace std;
#define N 2
struct Student{
string name;
int age;
};
int main()
{
struct Student stu[N];
ifstream fin("text.txt");
if(!fin){
cout<<"File open error!\n";
return 1;
}
for(int i = 0; i < N; i++)
{
fin >> stu[i].name;
fin >> stu[i].age;
}
for(i = 0; i < N; i++)
{
cout<<stu[i].name<<" "<<stu[i].age<<endl;
}
fin.close();
return 0;
}