个文件流对象,为啥不能关联2个文件

个文件流对象,为什么不能关联2个文件
#include<iostream>
#include<fstream>
using namespace std;

int  main(){
char temp[200];
ifstream fp;

fp.open("d:\\root.txt");
if(!fp){
cout<<" error"<<endl;
exit(1);
}
while(fp)
{
fp.getline(temp,200);
cout<<temp<<endl;
}
fp.close();

fp.open("d:\\out.txt");
if(!fp){
cout<<" error"<<endl;
exit(1);
}
while(fp)
{
fp.getline(temp,200);
cout<<temp<<endl;
}
fp.close();
}
为什么fp.open("d:\\out.txt");时,文件无法打开,即fp为假

------解决方案--------------------
请记得clear再open第二个。
另外,复用流对象,可以说永远是一个糟糕想法。