Skip to main content

System Programming MCQs with Answers

Practice important System Programming MCQs with answers and explanations.

Multiple Choice Questions

Q751: Which header field keeps track of the total number of records in the file?
  • A: numRecords
  • B: numNonEmptyRecords
  • C: referenceCount
  • D: recordCreationTime
View Answer
A

Q752: Which system time field in the RECORD struct represents the last time the record was accessed?
  • A: recordCreationTime
  • B: recordLastRefernceTime
  • C: recordUpdateTime
  • D: dataString
View Answer
B

Q753: What is the purpose of the CreateFile function in this code?
  • A: To create or open a file
  • B: To write data to a file
  • C: To read data from a file
  • D: To close a file
View Answer
A

Q754: What does the FILE_FLAG_RANDOM_ACCESS flag specify when opening a file?
  • A: Sequential access
  • B: Random access
  • C: Write-only
  • D: Read-only
View Answer
B

Q755: In the program, what happens if the record number entered is larger than the total records?
  • A: The program prompts to try again
  • B: The record is created automatically
  • C: The program deletes an old record
  • D: The program ignores the input
View Answer
A

Q756: What type is used to store the data string in each record?
  • A: TCHAR
  • B: char*
  • C: DWORD
  • D: RECORD
View Answer
A

Q757: What does the command 'r' do in this program?
  • A: Reads a record
  • B: Writes a record
  • C: Deletes a record
  • D: Quits the program
View Answer
A

Q758: What is checked immediately after opening the file handle (hFile)?
  • A: If the file was opened successfully
  • B: If the file contains data
  • C: If the file is empty
  • D: If the file is locked
View Answer
A

Q759: When deleting a record, what happens to the header's numNonEmptyRecords value?
  • A: It is decremented
  • B: It is incremented
  • C: It stays the same
  • D: It is reset to zero
View Answer
A

Q760: Which function is used to update the file pointer position?
  • A: SetFilePointerEx
  • B: SetFilePointer
  • C: MoveFile
  • D: SeekFile
View Answer
A

Test Your Knowledge

Take a timed quiz on System Programming

🚀 Start Quiz Now