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???????????
Answers were Sorted based on User's Feedback
Answer / manoj
Mode Type of file Read Write Create Truncate
"r" text yes no no no
"rb" binary yes no no no
"r+" text yes yes no no
"r+b" binary yes yes no no
"rb+" binary yes yes no no
"w" text no yes yes yes
"wb" binary no yes yes yes
"w+" text yes yes yes yes
"w+b" binary yes yes yes yes
"wb+" binary yes yes yes yes
"a" text no yes yes no
"ab" binary no yes yes no
"a+" text yes yes yes no
"a+b" binary no yes yes no
"ab+" binary no yes yes no
Is This Answer Correct ? | 2 Yes | 0 No |
Answer / 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 |
ABCDCBA ABC CBA AB BA A A
Hi Every one......... Please Any body give me the answer for my question. Is it possible to print the word "PRINT F", without using printf() statement in C-Language.
#include<stdio.h> void main() { char *str; long unsigned int add; str="Hello C"; add=&str[0]; printf("%c",add); } What is the output?
Explain how can I read and write comma-delimited text?
How to add two numbers without using arithmetic operators?
18 Answers College School Exams Tests, e track, Infosys, Pan Parag, Sapient, TCS,
Explain what is a pragma?
Which programming language is best for getting job 2020?
what does data structure mean?
1. Write a c pgm to print 1 to 100 without using loops. 2. Write a c pgm for leap year 3. Write a c pgm fibbonacci series,factorial 4. Write a c pgm count no of lines , blanks, tabs in a para(File concept) 5. Write a c pgm to print the letter as per given condition i.e.. if u give 4 out put should b 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 6.how do get the o/p in number from 1 to 100 in the screen without using control statement? 7. who do u print the word "hello world" without using "printf" statement? 8. write sql program to get the detail of student in a class? Definitions: structure union arrays linkedlist macros directives difference b/w pre processorsDiffrence: 1.Constructors and destructors 2.Structure and Union 3.Array and Lists 4.pre processor... 5. Privillages in C++ 6.structure and union 7.break and continue 8.while and dowhile Pgm..
int main() { int i=1; switch(i) { case '1': printf("hello"); break; case 1: printf("Hi"); break; case 49: printf("Good Morning"); break; } return 0; }
WHAT IS MEANT BY LIFE?
general for is %wd,f-d; in this system "w" means a) 'w' represent total width of digits b) 'w' represent width which includes the digits before,after decimal place and the decimal point c) 'w' represent width which includes the digits before only d) 'w' represent width after decimal place only