System Programming MCQs with Answers
Practice important System Programming MCQs with answers and explanations.
Chapter: 89
Q1881:
Which one of the following is NOT true about process handles?
A. They must be closed when not needed
B. They define security attributes
C. They are used by CreateProcess()
D. They are reused automatically
Correct Answer:
D
Chapter: 89
Q1882:
Process ID and handle can both be used to identify a process in function calls.
A. A
B. B
Correct Answer:
A
Chapter: 89
Q1883:
Process IDs are guaranteed to remain the same across process sessions.
A. A
B. B
Correct Answer:
B
Chapter: 89
Q1884:
CreateProcess() provides environment data to the new process.
A. A
B. B
Correct Answer:
A
Chapter: 89
Q1885:
Handle reuse across multiple processes is a default behavior.
A. A
B. B
Correct Answer:
B
Chapter: 89
Q1886:
Process ID is required when:
A. Working with threads
B. Using handle-based APIs
C. Monitoring process status
D. Opening a file
Correct Answer:
C
Chapter: 89
Q1887:
If a parent process changes its directory, the child process will:
A. Also change
B. Remain unaffected
C. Crash
D. Reboot the system
Correct Answer:
B
Chapter: 89
Q1888:
Handles with different ______ can exist for the same process.
A. names
B. priorities
C. security attributes
D. types
Correct Answer:
C
Chapter: 89
Q1889:
Once created, a process is:
A. Dependent on parent
B. Part of the parent's control
C. Completely standalone
D. Tied to environment
Correct Answer:
C
Chapter: 89
Q1890:
A process handle is a reference to:
A. Process structure
B. Process command line
C. An open instance of a process
D. Process memory pointer
Correct Answer:
C
Chapter: 89
Q1891:
Handles in Windows must be:
A. Saved to disk
B. Kept open permanently
C. Logged for audit
D. Closed when not in use
Correct Answer:
D
Chapter: 89
Q1892:
What type of structure are process handles compared to in the content?
A. File handle
B. Socket
C. Port
D. Thread handle
Correct Answer:
A
Chapter: 89
Q1893:
Changing the environment block of the parent process after child creation affects the child.
A. A
B. B
Correct Answer:
B
Chapter: 89
Q1894:
Handles are required for ______ process-related functions.
A. name-based
B. ID-based
C. handle-based
D. path-based
Correct Answer:
C
Chapter: 90
Q1895:
What parameter usually specifies the executable image in Windows process creation?
A. lpApplicationName
B. lpSystemName
C. lpCommandLine
D. lpDirectory
Correct Answer:
C
Chapter: 90
Q1896:
If lpCommandLine is used to specify the image, what should be the value of lpApplicationName?
A. NULL
B. EXE
C. STRING
D. 1
Correct Answer:
A
Chapter: 90
Q1897:
Which parameter must not be NULL if lpCommandLine is not used?
A. lpDirectory
B. lpApplicationName
C. lpStartupInfo
D. lpEnvironment
Correct Answer:
B
Chapter: 90
Q1898:
The full name of the application, including path and extension, should be specified in ______.
A. lpCommandLine
B. argv[0]
C. lpApplicationName
D. ProgramData
Correct Answer:
C
Chapter: 90
Q1899:
What file extensions should be included when using lpApplicationName?
A. .ini, .dll
B. .exe, .bat
C. .txt, .sys
D. .doc, .xml
Correct Answer:
B
Chapter: 90
Q1900:
Quotes within the string are ______ for long application names.
A. mandatory
B. optional
C. not allowed
D. required only for .BAT files
Correct Answer:
B