int main(){
for(int k=0;k<m;k++){
AddEdge(graph,rand()%n,rand()%n);
}
}
void AddEdge(Graph *graph,int v1, int v2)//加边
{
ofstream ocout;
ocout.open("city.txt");
if (v1 == v2){
cout<<"冗余边"<<v1<<" "<<v2<<endl;
ocout<<"冗余边"<<v1<<" "<<v2<<endl;
return;
}
}
应该怎么改啊,还没学文件