foo.cc: In function 'int main()':
foo.cc:17:16: error: 'N' was not declared in this scope
struct SR rec[N];
^
foo.cc:22:21: error: 'rec' was not declared in this scope
scanf("%d%s%s%d",&rec[i].id,rec[i].name,&rec[i].phone,rec[i].secs);
^~~
foo.cc:22:21: note: suggested alternative: 'getc'
scanf("%d%s%s%d",&rec[i].id,rec[i].name,&rec[i].phone,rec[i].secs);
^~~
getc
foo.cc:30:14: error: 'rec' was not declared in this scope
if(strcmp(rec[k].name,names[i])==0)
^~~
foo.cc:30:14: note: suggested alternative: 'getc'
if(strcmp(rec[k].name,names[i])==0)
^~~
getc
foo.cc:30:26: error: 'names' was not declared in this scope
if(strcmp(rec[k].name,names[i])==0)
^~~~~
foo.cc:30:26: note: suggested alternative: 'rename'
if(strcmp(rec[k].name,names[i])==0)
^~~~~
rename
foo.cc:37:11: error: 'names' was not declared in this scope
strcpy(names[index],rec[k].name);
^~~~~
foo.cc:37:11: note: suggested alternative: 'rename'
strcpy(names[index],rec[k].name);
^~~~~
rename
foo.cc:37:24: error: 'rec' was not declared in this scope
strcpy(names[index],rec[k].name);
^~~
foo.cc:37:24: note: suggested alternative: 'getc'
strcpy(names[index],rec[k].name);
^~~
getc
foo.cc:43:19: error: 'names' was not declared in this scope
cout<<i+1<<" "<<names[i]<<endl;
^~~~~
foo.cc:43:19: note: suggested alternative: 'rename'
cout<<i+1<<" "<<names[i]<<endl;
^~~~~
rename
[Hydro](https://hydro.ac)提供评测服务