Q11
In the context of operating systems, which of the following statements is/are correct with respect to paging?
More than one option can be correct.
Show answer without attempting
Answer: A, C
GATE CS · 9 questions
9 Operating Systems questions from GATE CS papers (2021), each with the official answer key. Answer any question right here and it is marked straight away, or practise them one at a time.
Answer: A, C
Answer: A, C
Answer: A, C
Answer: 12
1. int counter = 0;
2. Semaphore S = init(5);
3. void parop(void)
4. {
5. wait(S);
6. wait(S);
7. counter++;
8. signal(S);
9. signal(S);
10.}Answer: A, B, D
Answer: A, C, D
int x = 0; // global
Lock L1; // global
main() {
create a thread to execute foo(); // Thread T1
create a thread to execute foo(); // Thread T2
wait for the two threads to finish execution;
print (x);}
foo() {
int y = 0;
Acquire L1;
x = x + 1;
y = y + 1;
Release L1;
print (y);}Answer: A, D
function OWNRESOURCE(Resource R)
Acquire lock L // a global lock
if R is available then
Acquire R
Release lock L
else
if R is owned by another process P then
Terminate P, after releasing all resources owned by P
Acquire R
Restart P
Release lock L
end if
end if
end functionAnswer: A, B, C

Answer: 4108
0/90 correct0 marks