+ 1

What is wrong in the following code?

https://code.sololearn.com/c6Bp6EM9EZAo/?ref=app

13th Nov 2018, 11:48 PM
Abhay
Abhay - avatar
4 Réponses
+ 3
I am stumped. It looks like a compiler bug. Workaround: It works if you replace gets() with scanf(). By the way, gets() has fallen out of favor. It was removed from the C standard in 2011 because it opens a security hole. Avoid using gets().
14th Nov 2018, 12:04 AM
Brian
Brian - avatar
+ 2
16. scanf("%s",&p->a);
14th Nov 2018, 12:22 AM
Solo
Solo - avatar
+ 1
thks Brian ,
14th Nov 2018, 2:40 AM
Abhay
Abhay - avatar
0
pls help
13th Nov 2018, 11:51 PM
Abhay
Abhay - avatar