Contents

What is the return type open () method?
a) int                                      
b) char
c) boolean                            
d) float

c

What is the correct syntax for open () function in file handling?
a) myfile. open(file);
b) myfile. open[file];
c) myfile. open{file};
d) none of these

a

Which of the following statement is used to declare variable?
a) ifStream file; 
b) ifStream file();
c) ifStream file[];
d) ifStream file {}.

a

Which of the following mode flag is used for input/reading operation?
a) ios:: out                            
b) ios:: in
c) ios:: binary                      
d) ios:: ate

b

What is the correct format for reading file using object?
a) myFile >>c;    
b) myFile <<c;
c) myFile $$c;                     
d) myFile &&c;

a

Which of the following function is used to terminate automatically stream files?
a) new ()                                               
b) open ()
c) save ()                                               
d) close ()

d