in Object Oriented Programming retagged by
1,799 views
1 vote
1 vote

Match the following with respect to I/O classes in object oriented programming $:$

$\begin{array}{clcl}  & \textbf{List – I}&& \textbf{List – II} \\ \text{a.} & \text{fopen()} & \text{i.} & \text{returns end of file} \\ \text{b.} & \text{fclose()} & \text{ii.} & \text{return for any problem report} \\ \text{c.} & \text{ferror()} & \text{iii.} & \text{return 0} \\ \text{d.} & \text{feof()} & \text{iv.} & \text{returns a file pointer}  \\ \end{array} $

$\textbf{Codes :}$

  1. $\text{a-iv, b-i, c-ii, d-iii}$
  2. $\text{a-iii, b-i, c-iv, d-ii}$
  3. $\text{a-ii, b-iii, c-iv, d-i}$
  4. $\text{a-iv, b-iii, c-i, d-ii}$
in Object Oriented Programming retagged by
1.8k views

1 comment

Is the question incomplete.. Statements iii and iv on List II are not complete
0
0

1 Answer

3 votes
3 votes
Best answer

Answer : A

List – I                          List – II

a. fopen()                   iv. returns a file pointer on success and NULL otherwise

b. fclose()                  i. returns 0 on success and EOF otherwise

c. ferror()                  ii. checks the error indicator for the given file stream returning non-zero if set and 0 otherwise

d. feof()                    iii. checks the end of file indicator for the given file stream returning non-zero if set and 0 otherwise 

Reference :  fopen()  fclose()  ferror()  feof() 

selected by
Answer:

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true