+ 3

Explain the following code

#include<stdio.h> #include<string.h> struct player { char pname[20]; }pl; char* play(struct player *temp_pl) { strcpy(temp_pl->pname, "kohli"); return temp_pl->pname; } int main() { strcpy(pl.pname, "dhoni"); printf("%s %s", pl.pname, play(&pl)); return 0; }

30th May 2019, 2:42 PM
Srija Padmanabhuni
0 odpowiedzi