can you explain in brief what is "r+" mode in a file... i
know that it si used to read and modify rhe existing
content.... but explalanation about the file pointer in "r+"
mode i wann to know???????????
Answer Posted / abdur rab
When a file is opened with update mode ( '+' as the second
or third character in the mode argument), both input and
output may be performed on the associated stream. However,
writes cannot be followed by reads without an intervening
call to fflush or to a file positioning function (fseek,
fsetpos, or rewind), and reads cannot be followed by writes
without an intervening call to a file positioning function.
Since the file position is altered after read or write.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
Does c have class?
What is the full form of getch?
Explain 'bit masking'?
What is the function of volatile in c language?
Explain how do you print an address?
how can f be used for both float and double arguments in printf? Are not they different types?
Can we use any name in place of argv and argc as command line arguments?
program to convert a integer to string in c language'
Why flag is used in c?
Is linux written in c?
Explain which of the following operators is incorrect and why? ( >=, <=, <>, ==)
What is the purpose of scanf() and printf() functions?
Are negative numbers true in c?
How is pointer initialized in c?
How are strings stored in c?