Introduction to Computing MCQs with Answers
Practice important Introduction to Computing MCQs with answers and explanations.
Multiple Choice Questions
Q2261: What is the lost update problem in a database system?
- A: Two transactions making deductions from the same account without reflecting each other's changes
- B: One transaction incorrectly summarizing data
- C: Two transactions sharing data with incorrect access levels
- D: A transaction being rolled back due to errors
View Answer
B
Q2262: What is the primary purpose of a locking protocol in a database system?
- A: To prevent interactions between transactions that can cause erroneous results
- B: To speed up the execution of transactions
- C: To provide automatic backups
- D: To recover lost data
View Answer
A
Q2263: What does an exclusive lock in a database protocol allow a transaction to do?
- A: Alter the data item exclusively while preventing other transactions from accessing it
- B: Share access with other transactions
- C: Read the data item without making changes
- D: Remove the lock from the data item
View Answer
A
Q2264: What happens if a transaction requests shared access to an item that already has an exclusive lock?
- A: The request is denied and the transaction must wait
- B: The transaction is granted access immediately
- C: An error is logged and the transaction is rolled back
- D: The item is unlocked for shared access
View Answer
A
Q2265: How does a scheduler in a DBMS help manage transactions?
- A: It coordinates time-sharing among transactions, similar to multiprogramming in operating systems
- B: It forces transactions to execute one at a time
- C: It logs all transactions for recovery
- D: It allocates additional resources to transactions
View Answer
B
Q2266: What is the purpose of the wound-wait protocol in database systems?
- A: To avoid deadlocks by giving priority to older transactions over younger transactions
- B: It speeds up transaction processing
- C: It ensures that all transactions are executed immediately
- D: It prevents transactions from rolling back
View Answer
D
Q2267: Fill in the blank: In a locking protocol, if a transaction requests exclusive access to an item with an existing lock, the request is __________.
- A: Denied
- B: Granted
- C: Logged
- D: Processed
View Answer
A
Q2268: What type of lock is used to allow multiple transactions to read but not alter a data item?
- A: Shared lock
- B: Exclusive lock
- C: Temporary lock
- D: Volatile lock
View Answer
A
Q2269: What is a consequence of a deadlock in a database system?
- A: Two transactions blocking each other's progress due to mutual exclusive access requests
- B: Immediate transaction completion
- C: Automatic resolution of conflicting transactions
- D: Unlimited access to all transactions
View Answer
A
Q2270: Fill in the blank: A database management system uses __________ to ensure that transactions are executed without causing anomalies like incorrect summaries.
- A: Schedulers and locking protocols
- B: Log files and backups
- C: Temporary storage and memory
- D: Backup copies and error logs
View Answer
A