MCQs
Total Questions : 97
| Page 10 of 10 pages
Question 91. In a k-way set associative cache, the cache is divided into v sets, each of which consists of k lines. The lines of a set are placed in sequence one after another. The lines in set s are sequenced before the lines in set (s+1). The main memory blocks are numbered 0 onwards. The main memory block numbered j must be mapped to any one of the cache lines from
Answer: Option A. -> (j mod v) * k to (j mod v) * k + (k-1)
-NA-
Answer: Option C. -> Θ(n3)
-NA-
Answer: Option D. -> x' ⊕ y'
-NA-
Question 94. Consider the following relational schema. Students(rollno: integer, sname: string) Courses(courseno: integer, cname: string) Registration(rollno: integer, courseno: integer, percent: real)Which of the following queries are equivalent to this query in English?"Find the distinct names of all students who score more than 90% in the course numbered 107(I) SELECT DISTINCT S.snameFROM Students as S, Registration as RWHERE R.rollno=S.rollno AND R.courseno=107 AND R.percent >90(II) Πsname = (σcourseno=107 ∧ percent>90 (Registration ⋈ Students))(III) {T|ƎSϵ Students, ƎRϵ Registration ( S.rollno=R.rollno ∧ R.courseno=107 ∧ R.percent>90 ∧T.sname=S.sname)} (IV) {(SN) | ƎSRƎRP ((SR, SN)ϵ Students ∧ SR, 107, RP > ϵ Registration ∧ RP>90)}
Answer: Option A. -> I, II, III and IV
-NA-
Answer: Option D. -> Complement of L1 is context-free but not regular.
-NA-
Question 96. A shared variable x, initialized to zero, is operated on by four concurrent processes W, X, Y, Z as follows. Each of the processes W and X reads x from memory, increments by one, stores it to memory, and then terminates. Each of the processes Y and Z reads x from memory, decrements by two, stores it to memory, and then terminates. Each process before reading x invokes the P operation (i.e., wait) on a counting semaphore S and invokes the V operation (i.e., signal) on the
semaphore S after storing x to memory. Semaphore S is initialized to two. What is the maximum possible value of x after all processes complete execution?
semaphore S after storing x to memory. Semaphore S is initialized to two. What is the maximum possible value of x after all processes complete execution?
Answer: Option D. -> 2
-NA-
Answer: Option B. -> 2
-NA-