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
Why is it usually a bad idea to use gets()? Suggest a workaround.
What is the use of a static variable in c?
Difference between malloc() and calloc() function?
write a program to convert a expression in polish notation(postfix) to inline(normal) something like make 723+* (2+3) x 7 (not sure) just check out its mainly printing expression in postfix form to infix.
What does 1f stand for?
How do you convert strings to numbers in C?
Can you define which header file to include at compile time?
Why is c not oop?
What are called c variables?
plz let me know how to become a telecom protocol tester. thank you.
Can one function call another?
What is a function in c?
Write a program to replace n bits from the position p of the bit representation of an inputted character x with the one's complement. Method invertBit takes 3 parameters x as input character, p as position and n as the number of positions from p. Replace n bits from pth position in 8 bit character x. Then return the characters by inverting the bits.
Write a program to print all permutations of a given string.
What is the difference between char array and char pointer?