On 15 May, 04:26, Mohd Azhar Hussain <azhar...@gmail.com> wrote:
> I am new to C. I was trying to read input from key board using scanf,
A huge mistake, IMHO and I'm not alone in that opinion. See large
parts of
http://c-faq.com/stdio/index.html, notably
http://c-faq.com/stdio/scanfprobs.html.
> what does scanf("hai") mean?
> Is there any special meaning if i give '\n' in scanf?
If you read the manual (and perhaps the FAQ) carefully, I expect it
will tell it, frankly I don't know and don't care.
In common with strtok(), the number of places where scanf() is the
correct solution to a problem can almost be counted on the fingers of
one foot, and interactive input is definitely not in that set. It
should be very low on the list of functions for a learner to try to
work with...