Skip to main content

System Programming MCQs with Answers

Practice important System Programming MCQs with answers and explanations.

Multiple Choice Questions

Q1921: What flag in CreateProcess() determines if handles are inherited?
  • A: bInheritFlag
  • B: bInheritHandles
  • C: handleFlag
  • D: processFlag
View Answer
B

Q1922: Which structure must be used to make individual handles inheritable?
  • A: STARTUPINFO
  • B: PROCESS_INFORMATION
  • C: SECURITY_ATTRIBUTES
  • D: HANDLE_ATTRIBUTES
View Answer
C

Q1923: The nLength member of SECURITY_ATTRIBUTES must be set to ______.
  • A: sizeof(HANDLE)
  • B: sizeof(int)
  • C: sizeof(SECURITY_ATTRIBUTES)
  • D: MAX_LENGTH
View Answer
C

Q1924: Which of the following handles is typically inherited by a child process?
  • A: Database handles
  • B: Standard input and output handles
  • C: File descriptors
  • D: Memory pointers
View Answer
B

Q1925: A child process can directly receive a copy of the parent's open handles if those handles are ______.
  • A: closed
  • B: protected
  • C: inheritable
  • D: reserved
View Answer
C

Q1926: The purpose of inheriting handles is to share access to ______ between parent and child processes.
  • A: shared memory
  • B: user interface
  • C: system settings
  • D: resources like input/output
View Answer
A

Q1927: To make a handle inheritable, the SECURITY_ATTRIBUTES must include a flag called ______.
  • A: handleFlag
  • B: bInheritFlag
  • C: securityMode
  • D: accessLevel
View Answer
B

Q1928: The process of handle inheritance is defined at the time of ______.
  • A: closing the handle
  • B: declaring the variable
  • C: creating the process
  • D: ending the process
View Answer
C

Q1929: Which flag in the SECURITY_ATTRIBUTES structure must be explicitly set for handle inheritance?
  • A: bSecurityFlag
  • B: bInheritFlag
  • C: inheritMode
  • D: securityAccess
View Answer
B

Q1930: When should the nLength in SECURITY_ATTRIBUTES be assigned sizeof(SECURITY_ATTRIBUTES)?
  • A: before using the structure
  • B: when closing the handle
  • C: when accessing memory
  • D: after CreateProcess()
View Answer
A

Test Your Knowledge

Take a timed quiz on System Programming

🚀 Start Quiz Now