struct Album {
string title;
string year;
string track;
vector<string> tracks;
}MyAlbums[5];
int j;
Album temp;
for(int i = 1; i < 5; i++)
{
j = i - 1;
while( j >= 0 && strcmp( MyAlbums[j+1].title[0], MyAlbums[j].title[0]) < 0 ){
temp = MyAlbums[j + 1];
MyAlbums[j+1] = MyAlbums[j];
MyAlbums[j] = temp;
j--;
}
}
给我这个:从 'char' 到 'const char*' 的无效转换 [-fpermissive]