+ 1
help me! I do not know what happened to my code. I want to put information from scanf into printf but the result is not as I e
https://code.sololearn.com/c7zoXxecgIl7/?ref=app help me! I do not know what happened to my code. I want to put information from scanf into printf but the result is not as I expected. thanks everyone.
3 Antworten
+ 8
I guess problem is, you're using scanf() statment at last, which isn't valid.
You have to take inputs before you print them.
So move scanf() statement right before print statement, it works🤓
+ 5
Phuong Pham, you are printing the values before reading them, so it displayes whatever values where stored in that address (known as garbage values)
So to correct that just like 🎃 Dark Knight 🎃 said, put scaf first
https://code.sololearn.com/coJWqfyET7A2/?ref=app
+ 1
Thank you very much, I understand😉😆😆