Darko said:
asit dhal wrote:
can anyone explain me how to use read() write() function in C.
and also how to read a file from disk and show it on the monitor
using onlu read(), write() function ??????
There is no read nor write function in C. Look up such things as
fopen, fclose, fread, fwrite. [snip]
Let be honest, then, there are no functions fopen, fclose, fread,
fwrite neither in C.
Umm, the C standard says otherwise.
I am sorry to have disturbed emotions of so many people here, I did
not intend to do that. Luckily, my employer is not so tough and strict
as some of you folks are, so I think I won't get fired soon. Maybe
later.
As Keith Thompson noticed, the ISO 9899 C standard also lists
functions in the Library section, but I wouldn't dare calling it a
"minor quibble". Since, if one took to read the whole standard or at
least to look at it in detail, would see some key sentences when the
author(s) clearly distinguished the Language and the Library.
Furthermore, besides the Standard Library, there are other things that
this document talks about, which are also not a part of the language.
[snip]
Your original statement (see above) was that
"... there are no functions fopen, fclose, fread, fwrite neither
in C."
You didn't distinguish between the language and the library, you just
said "in C". Both the "language" (described in section 6 of the
standard) and the "library" (described in section 7) are indisputably
part of C. Your statement was quite simply incorrect, and any
distinction between "language" and "library" has nothing to do with
it.
For that matter, the standard document as a whole is titled
"Programming Languages -- C". The term "language" is ambiguous; it
can refer either to what's described in section 6 of the standard, or
to what's described by the standard as a whole, including the library.
And I'm afraid that your error was a particularly blatant one. It's
almost as if you had claimed that C doesn't have pointers, or that it
doesn't have functions.
I'm not saying this to be personally offensive. I'm merely trying to
help you understand why there was such a strong reaction.
This isn't about anger, or courage, or "disturbed emotions", or
anything like that. This newsgroup is a community that values
*correctness* above almost everything else. I've made mistakes here
myself; no doubt some of them have been particularly boneheaded (no
need to search for examples, thank you very much). One of the best
things about this newsgroup is that mistakes are corrected.
And now, you seem to be trying to justify your original statement,
rather than simply admitting that you were mistaken.
The reaction to your error may have seemed excessive, but it's a
consequence of the way Usenet works. Usenet is fundamentally an
asynchronous medium. Most of the respones were written before the
responders had seen any of the other responses. I understand that it
seemed like everyone was ganging up on you, but that wasn't the
intent.
[...]
I am sorry again to have annoyed you, I know I'm offending your sense
of being the smartest and the completest programmers, but there is
such thing as fair and civilised argument that's not supposed to have
words "crap" in it and rude behaviour.
Again, that's not what this is about. As for rudeness, I seriously
suggest you try to grow a thicker skin. Yes, there's some rudeness
here; it's best to ignore it and pay attention to the underlying
message.
[...]
So, instead of saying "sod off" to all of you, which I should, I will
just let you be what you are. Have a nice day.
Well, I'm sure we're all grateful that you merely *insinuated* saying
"sod off" to all of us, rather than coming out and saying it. The
quotation marks really help to soften the blow. (Did you know that
the word "disingenuous" isn't in the dictionary?)