+ 1
hello guys beginner in c language, is it possible to get the user output, if yes how?
another c problem : <
16 odpowiedzi
+ 4
MIkko Celestra Mercado
yes you can used scanf()
to get input from user
like this..
this is a program to calculated a leap year
https://code.sololearn.com/cHOQ85w4GrPi/?ref=app
+ 4
MIkko Celestra Mercado
dont say sorry every time you asked something..
we all happy to see that you try your best to learn
+ 4
well say
Fata1 Err0r
+ 3
I not really understand your questions..
can you be more specific.
+ 3
https://www.tutorialspoint.com/c_standard_library/c_function_scanf.htm
^Go there and scroll down to where it says "EXAMPLE." It shows you how to store the input and how to send the input to the user as output.
scanf("%s", str1);
^That's taking in input and storing it into the variable 'str1'
printf("Entered Name: %s\n", str1);
^That's taking our input that we stored in 'str1' and sending it to the user as output to their screen.
+ 2
I think you meant 'user input' instead.
https://www.tutorialspoint.com/c_standard_library/c_function_scanf.htm
^You can use the scanf() function for such purposes.
I'd recommend that you read all the way through the language first, even if you don't understand it fully yet. Then practice what you could remember and read through all of it again; this time write down notes of anything you still don't understand. Extensively research everything that's written down on your notes and then practice them to further solidify your learning. Repeat that process until you're no longer having to write anything down on your notes. For myself, this has been the best method for learning all of the languages that I know.
+ 2
oh okay thanks again
+ 2
Oh okay sir😁
+ 2
thanks for helping me i really appreciated it
+ 2
You're welcome.
As Arun said, you've no need to apologize, especially over being new to something. Trust me, ALL of us here were new to this at one point or another, and just as lost/confused in the process of learning it all. That's nothing to apologize about. The fact that you're trying to learn programming to begin with is very commendable. Programming isn't for everyone and most give up before they even finish learning their first language.
+ 2
thank you, thank you so much sir 🙏
+ 2
thanks a lot
+ 1
" Is it possible to get the user input using c language"?
+ 1
oh can you write a code using scanf() please, sorry i am beginner in c
0
but here is my question again, how do i store the user's input and use it on printf
0
how do i set it