Basic and Advance C Question:
Download Job Interview Questions and Answers PDF
Why doesnt the call scanf work?
Answer:
Why doesn't the call scanf("%d", i) work?
The arguments you pass to scanf must always be pointers: for each value converted, scanf ``returns'' it by filling in one of the locations you've passed pointers to. To fix the fragment above, change it to scanf("%d", &i) .
The arguments you pass to scanf must always be pointers: for each value converted, scanf ``returns'' it by filling in one of the locations you've passed pointers to. To fix the fragment above, change it to scanf("%d", &i) .
Download C Programming Interview Questions And Answers
PDF
Previous Question | Next Question |
Why does the call char scanf work? | Why doesnt long int work? |