Professional KnowledgeHardIBPS SO IT
Two processes P and Q share variable X=0. P does X=X+1 and Q does X=X+1 (each: load, add, store) without synchronisation. Possible final values:
- A. Only 2
- B. 1 or 2
- C. Only 1
- D. 0, 1 or 2
Correct answer: B. 1 or 2
With interleaving, one update can be lost giving 1; otherwise 2.
Practise more IT Officer Professional Knowledge (IBPS SO) questionsIT Officer Professional Knowledge (IBPS SO): notes and key points
More IT Officer Professional Knowledge (IBPS SO) questions
- Which is a non-preemptive scheduling algorithm?
- The process state that follows 'running' when its time quantum expires is:
- Locality of reference supports which of these?
- Cache: direct-mapped, 64 KB, block size 16 bytes, 32-bit address. Tag bits:
- The time to build a binary heap from n arbitrary elements using the bottom-up (Floyd) method is:
- Preorder of a BST is 50, 30, 20, 40, 70, 60, 80. Its postorder is: