C- Library Functions MCQ

C- Library Functions MCQ
1. What will the function rewind() do?
  • Reposition the file pointer to a character reverse.
  • Reposition the file pointer stream to end of file.
  • Reposition the file pointer to begining of that line.
  • Reposition the file pointer to begining of file.
Show Answer
2. Input/output function prototypes and macros are defined in which header file?
  • conio.h
  • stdlib.h
  • stdio.h
  • dos.h
Show Answer
3. Which standard library function will you use to find the last occurance of a character in a string in C?
  • strnchar()
  • strchar()
  • strrchar()
  • strrchr()
Show Answer
4. What is stderr ?
  • standard error
  • standard error types
  • standard error streams
  • standard error definitions
Show Answer
5. Does there any function exist to convert the int or float to a string?
  • Yes
  • No
Show Answer
6. What is the purpose of fflush() function.
  • flushes all streams and specified streams.
  • flushes only specified stream.
  • flushes input/output buffer.
  • flushes file buffer.
Show Answer
7. Can you use the fprintf() to display the output on the screen?
  • Yes
  • No
Show Answer
8. What will the function randomize() do in Turbo C under DOS?
  • returns a random number.
  • returns a random number generator in the specified range.
  • returns a random number generator with a random value based on time.
  • return a random number with a given seed value.
Show Answer
9. Which header file should be included to use functions like malloc() and calloc()?
  • memory.h
  • stdlib.h
  • string.h
  • dos.h
Show Answer
Questions and Answers for Competitive Exams Various Entrance Test