Consider a stack $S$ and a queue $Q$. Both of them are initially empty and have the capacity to store ten elements each. The elements $1,2,3,4$, and 5 arrive one by one, in that order. When an element arrives, it is assigned either to $S$ (pushed on $S$ ) or to $Q$ (enqueued to $Q)$. Once all the five elements are stored, the output is generated in two steps. First, stack $S$ is emptied by popping all elements. Then queue $Q$ is emptied by dequeueing all elements. The output obtained by following this process is 43125 .
Given the output, the objective is to predict whether an element was assigned to $S$ or $Q$. Which of the following options is/are possible valid assignment(s) of the elements?
Note: In the options, the notation $x S$ denotes that element $x$ was assigned to $S$ and $y Q$ denotes that element $y$ was assigned to $Q$.
$$ \text { In the context of DBMS, consider the two sets } \mathbf{T} \text { and } \mathbf{S} \text { given below. } $$
$$ \begin{array}{ll}\,\,\,\,\, \text { T } &\,\,\,\,\, \text { S } \\ \text { I: } \text { Logical schema } & \text { L: Views } \\ \text { II: } \text { Physical schema } & \text { M: File organization and indexes } \\ \text { III: External schema } & \text { N: Relations } \end{array} $$
Which one of the following is the correct match from $T$ to $S$ ?
Consider concurrent execution of two transactions $T 1$ and $T 2$ in a DBMS, both of which access a data object $A$. For these two transactions to not conflict on $A$, which one of the following statements must be true?
In the context of schema normalization in relational DBMS, consider a set $F$ of functional dependencies. The set of all functional dependencies implied by $F$ is called the closure of $F$. To compute the closure of $F$, Armstrong's Axioms can be applied. Consider $X, Y$, and $Z$ as sets of attributes over a relational schema. The three rules of Armstrong's Axioms are described as follows.
Reflexivity: If $Y \subseteq X$, then $X \rightarrow Y$
Augmentation: If $X \rightarrow Y$, then $X Z \rightarrow Y Z$ for any $Z$
Transitivity: If $X \rightarrow Y$ and $Y \rightarrow Z$, then $X \rightarrow Z$
The additional rule of Union is defined as follows.
Union: If $X \rightarrow Y$ and $X \rightarrow Z$, then $X \rightarrow Y Z$
It can be proved that the additional rule of Union is also implied by the three rules of Armstrong's Axioms. Listed below are four combinations of these three rules. Which one of these combinations is both necessary and sufficient for the proof?
GATE CSE Papers
All year-wise previous year question papers