System Programming MCQs with Answers
Practice important System Programming MCQs with answers and explanations.
Chapter: 39
Q881:
The UNIX touch command is equivalent to which Windows API functionality?
A. SetFileTime
B. GetSystemTime
C. GetSystemTimeAsFileTime
D. FileTimeToSystemTime
Correct Answer:
A
Chapter: 40
Q882:
The C library for file processing is portable to operating systems other than ________.
A. Windows
B. Linux
C. Unix
D. MacOS
Correct Answer:
A
Chapter: 40
Q883:
C library file processing functions are mainly ________ and character-oriented.
A. line
B. stream
C. buffer
D. block
Correct Answer:
B
Chapter: 40
Q884:
The C library functions for file processing are ________ level compared to Windows functions.
A. lower
B. higher
C. equal
D. none
Correct Answer:
B
Chapter: 40
Q885:
Functions in C library for file processing can be migrated to ________ calls.
A. generic
B. Windows-specific
C. Hardware-specific
D. Assembly
Correct Answer:
A
Chapter: 40
Q886:
A major advantage of C library file processing functions is that they are ________ to use.
A. complex
B. easy
C. inefficient
D. confusing
Correct Answer:
B
Chapter: 40
Q887:
The C library file processing functions mainly perform ________ processing.
A. string
B. file
C. disk
D. memory
Correct Answer:
A
Chapter: 40
Q888:
Compared to Windows functions, C library functions have some ________ advantages.
A. performance
B. security
C. portability
D. none
Correct Answer:
A
Chapter: 40
Q889:
Which of the following is a limitation of the C library file processing?
A. High performance
B. Lack of portability
C. Some limitations
D. Easy migration
Correct Answer:
C
Chapter: 40
Q890:
C library file processing functions handle files at a ________ level than Windows functions.
A. hardware
B. high
C. level
D. low
Correct Answer:
B
Chapter: 40
Q891:
C library file processing functions are suitable for ________ systems.
A. only Windows
B. only Linux
C. multiple operating
D. most embedded
Correct Answer:
D
Chapter: 40
Q892:
The portability of C library file processing functions means they can work on ________.
A. only Windows
B. only Linux
C. other than Windows
D. only DOS
Correct Answer:
C
Chapter: 40
Q893:
Which C library function category is convenient for string processing?
A. Binary functions
B. Line and character-oriented functions
C. Windows-specific functions
D. Hardware functions
Correct Answer:
B
Chapter: 41
Q894:
Windows OS can lock ________ or part of a file.
A. Only entire files
B. Only file headers
C. Only file footers
D. Complete files or parts
Correct Answer:
D
Chapter: 41
Q895:
Which function is used to lock files in Windows?
A. LockFile
B. UnlockFileEx
C. LockFileEx
D. OpenFile
Correct Answer:
C
Chapter: 41
Q896:
The function LockFileEx returns a value of type ________.
A. BOOL
B. INT
C. VOID
D. HANDLE
Correct Answer:
A
Chapter: 41
Q897:
The parameter hFile in LockFileEx represents the ________.
A. File handle
B. File size
C. File name
D. File pointer
Correct Answer:
A
Chapter: 41
Q898:
The dwFlags parameter in LockFileEx is used to specify ________.
A. Locking options
B. File size
C. Memory address
D. Buffer size
Correct Answer:
A
Chapter: 41
Q899:
To unlock a locked file, the function ________ is used.
A. LockFile
B. UnlockFileEx
C. LockFileEx
D. CloseFile
Correct Answer:
B
Chapter: 41
Q900:
The number of bytes to lock is specified by which parameters in LockFileEx?
A. dwFlags and dwReserved
B. nNumberOfBytesToLockLow and nNumberOfBytesToLockHigh
C. hFile and lpOverlapped
D. None of these
Correct Answer:
B