What happens when you attempt to compile and run the following code?
#include
using namespace std;
void set(struct person*);
struct person
{
char name[25];
int age;
};
int main()
{
struct person e = {"Steve", 30};
set(&e);
cout<< e.name << " " << e.age;
return 0;
}
void set(struct person *p)
{
p?>age = p?>age + 1;
}
Judy
3 months agoKatlyn
4 months agoKatie
4 months agoDelbert
4 months agoAlberto
4 months agoShawnee
5 months agoDorcas
5 months agoDarell
5 months agoMalissa
5 months agoRyann
5 months agoKris
5 months agoFranchesca
5 months agoAntonio
5 months agoTran
5 months agoJeannetta
5 months agoPamela
5 months agoDorinda
6 months agoHan
10 months agoCherrie
9 months agoChi
9 months agoElbert
9 months agoJannette
10 months agoShawnda
9 months agoKenneth
9 months agoDonte
10 months agoLing
10 months agoSabrina
9 months agoAnglea
9 months agoBettina
10 months agoLisha
11 months agoShawnda
9 months agoKizzy
10 months agoDanica
10 months agoDannie
10 months agoTasia
11 months agoKing
10 months agoKing
10 months agoMicaela
11 months agoLeota
11 months agoMicaela
11 months ago