![]() |
#2
rjsp2012-12-03 09:40
|

#include<iostream>
#include<string>
#include<utility>
typedef pair<string,string> Author;
using namespace std;
int main ()
{
string firstBook;
Author proust("Marcel", "Proust");
Author joyce("James", "joyce");
if (Author.first == "James" && Athor.sencond == "Joyce")
firstBook = "Stephen Hero" ;
cout << << "The firstBook is " << firstBook << endl;
system("pause");
}
报错求解? #include<string>
#include<utility>
typedef pair<string,string> Author;
using namespace std;
int main ()
{
string firstBook;
Author proust("Marcel", "Proust");
Author joyce("James", "joyce");
if (Author.first == "James" && Athor.sencond == "Joyce")
firstBook = "Stephen Hero" ;
cout << << "The firstBook is " << firstBook << endl;
system("pause");
}