Skip to main content

System Programming MCQs with Answers

Practice important System Programming MCQs with answers and explanations.

Multiple Choice Questions

Q1241: What happens if Handler returns FALSE?
  • A: Handler restarts
  • B: Event is ignored
  • C: Next handler is called
  • D: Program terminates
View Answer
C

Q1242: Which control signal is triggered when the console is closed?
  • A: CTRL_LOGOFF_EVENT
  • B: CTRL_CLOSE_EVENT
  • C: CTRL_C_EVENT
  • D: CTRL_BREAK_EVENT
View Answer
B

Q1243: The handler routine runs in a(n) _______ thread.
  • A: main
  • B: independent
  • C: parallel
  • D: shared
View Answer
B

Q1244: Signals apply to the whole process, while exceptions apply to _______.
  • A: all threads
  • B: the handler only
  • C: a single thread
  • D: the whole system
View Answer
C

Q1245: The loop in the main function will stop executing when ______.
  • A: the system reboots
  • B: exitFlag becomes TRUE
  • C: the user presses Enter
  • D: main ends
View Answer
B

Q1246: Console control handlers are used to detect ______.
  • A: compiler errors
  • B: console related events
  • C: keyboard shortcuts
  • D: network interrupts
View Answer
B

Q1247: If Handler is NULL and Add is TRUE in SetConsoleCtrlHandler, what happens?
  • A: The console shuts down
  • B: The event is logged
  • C: Ctrl-C is ignored
  • D: Error occurs
View Answer
C

Q1248: The value of dwCtrlType determines ______.
  • A: thread priority
  • B: loop count
  • C: control signal type
  • D: memory location
View Answer
C

Q1249: The system invokes the handler in which order?
  • A: reverse order of registration
  • B: random order
  • C: same order as added
  • D: default order
View Answer
A

Q1250: Sleep(4000) delays execution for ______.
  • A: 4 milliseconds
  • B: 4 minutes
  • C: 4 seconds
  • D: 400 seconds
View Answer
C

Test Your Knowledge

Take a timed quiz on System Programming

🚀 Start Quiz Now