Skip to main content

System Programming MCQs with Answers

Practice important System Programming MCQs with answers and explanations.

Multiple Choice Questions

Q441: Which function is used to change the standard IO handle to a new handle?
  • A: GetStdHandle()
  • B: SetStdHandle()
  • C: CloseHandle()
  • D: OpenHandle()
View Answer
B

Q442: Which header file includes all required Windows API functions for the given program?
  • A:
  • B:
  • C:
  • D:
View Answer
C

Q443: What is the purpose of the Options() function in the program?
  • A: Display files
  • B: Copy files
  • C: Parse command line options
  • D: Handle errors
View Answer
C

Q444: The Options() function checks for a prefix _______ to identify command line options.
  • A: --
  • B: /
  • C: -
  • D: *
View Answer
C

Q445: Which data type is used to hold flags for options in the Options() function?
  • A: LPBOOL
  • B: DWORD
  • C: LPSTR
  • D: BOOL
View Answer
A

Q446: The Options() function uses which macro to start processing variable arguments?
  • A: va_start
  • B: va_arg
  • C: va_end
  • D: va_list
View Answer
A

Q447: In the Options() function, the loop continues until all flags are checked or ________ is reached.
  • A: argc
  • B: iFlag
  • C: optStr length
  • D: iArg
View Answer
D

Q448: What does the CatFile function do in this program?
  • A: Open a file
  • B: Copy contents from one file handle to another
  • C: Close a file
  • D: Display file name
View Answer
B

Q449: In CatFile, what is the purpose of the buffer array?
  • A: Store file names
  • B: Store data to be copied
  • C: Store error messages
  • D: Store file handles
View Answer
B

Q450: What Windows API function reads data from a file handle in CatFile?
  • A: WriteFile
  • B: ReadFile
  • C: CreateFile
  • D: DeleteFile
View Answer
B

Test Your Knowledge

Take a timed quiz on System Programming

🚀 Start Quiz Now