I dont know why. sometime, when performing scanf it require & while sometime(in string), it dont.
printf("%d",&num1); <---------------no string
printf("%s",num1); <----------------string
ty.
I dont know why. sometime, when performing scanf it require & while sometime(in string), it dont.
printf("%d",&num1); <---------------no string
printf("%s",num1); <----------------string
ty.
You should (almost) never use & with printf, as it takes the value of its arguments, not a pointer (except when using strings...). You should (almost) always use & with scanf as it need to write to the arguments passed to the function.