(a) Suppose we have a database consisting of the following three relations.…
PYQ GATE 1998Modified — slightly modified from the official paper; see the solution
(a) Suppose we have a database consisting of the following three relations.
FREQUENTS (student, parlor) giving the parlors each student visits.
SERVES (parlor, ice-cream) indicating what kind of ice-creams each parlor serves.
LIKES (student, ice-cream) indicating what ice-creams each student likes.
(Assume that each student likes at least one ice-cream and frequents at least one parlor)
Express the following in SQL:
Print the students that frequent at least one parlor that serves some ice-cream that they like.
(b) In a computer system where the ‘best-fit’ algorithm is used for allocating ‘jobs’ to ‘memory partitions’ the following situation was encountered:
Partitions sizes in KB | 4K 8K 20K 2K |
Jobs sizes in KB | 2K 14K 3K 6K 6K 10K 20K 2K |
Time for execution | 4 10 2 1 4 1 8 6 |
When will the 20K job complete? Assume all jobs are available at time 0 and each partition serves jobs assigned by best fit in the printed order.
Attempted by 1 students.
Sign up free to check your answer
Sign up freeLoading lesson…

