# Recent activity by dhairya

1
(P + Q’) (PQ’ + PR) (P'Q’+PR) (P’R’ + Q’) simplifies to (A) PQ’ (B) PQ’+ R (C) PR’ (D) PR’ + Q
2
Consider the following expressions: $false$ $Q$ $true$ $P\vee Q$ $\neg Q\vee P$ The number of expressions given above that are logically implied by $P \wedge (P \Rightarrow Q)$ is ___________.
3
A probability density function density function is of form P(x)= k e ^(-a |x|) , the value of k is A)0.5 B)1 C) 0.5 a D) a
4
5
Consider line number $3$ of the following C-program. int main() { /*Line 1 */ int I, N; /*Line 2 */ fro (I=0, I<N, I++); /*Line 3 */ } Identify the compiler’s response about this line while creating the object-module: No compilation error Only a lexical error Only syntactic errors Both lexical and syntactic errors
6
1)If two fair dice is rolled ,find the probability that sum is 6 when 1st die is 4 2)find the probability of getting a 2 in the second dice if first die is 4 can we say these two are same question beacuse for 1st one answer is 1/5 for second one it is coming 1/6 Reason: in 1st one we can not consider the cases where 6 comes in 1st die in sample space,coz no chance of sum coming 6 then
7
a = b + " cde " ; Which phase of compiler will give error ?
8
S-> AB / Ɛ A-> AC / 0C B->0S C->1 What is the first (A)..??
9
Find the first of RHS of  A->AB/$\epsilon$
10
Consider the following recursive C function. void get(int n) { if (n<1) return; get (n-1); get (n-3); printf("%d", n); } If $get(6)$ function is being called in $main()$ then how many times will the $get()$ function be invoked before returning to the $main()$? $15$ $25$ $35$ $45$
11
Find first and follow... S→ABa / bCA A→cBCD / є B→CdA / ad C→eC / є D→bsf / a
12
Consider 3 relation R(A, B, C) WITH 20 TUPLES and S(A,D , E) With 30 tuples and T(D,F,G ) with 40 tuples. What is the max no. of tuples in natural joint of R S T Plz explain
13
Consider the depth-first-search of an undirected graph with $3$ vertices $P$, $Q$, and $R$. Let discovery time $d(u)$ represent the time instant when the vertex $u$ is first visited, and finish time $f(u)$ represent the time instant when the vertex $u$ ... connected There are two connected components, and $Q$ and $R$ are connected There are two connected components, and $P$ and $Q$ are connected
14
A circularly linked list is used to represent a Queue. A single variable $p$ is used to access the Queue. To which node should $p$ point such that both the operations $\text{enQueue}$ and $\text{deQueue}$ can be performed in constant time? rear node front node not possible with a single pointer node next to front
15
Consider the following C function: int f(int n) { static int r = 0; If (n < = 0) return 1; If (n > 3) { r = n; return f (n &ndash; 2) + 2; } return f(n &ndash; 1) + r; } What is the value of f(5)? (A) 3 (B) 7 (C) 9 (D) 18
16
"a healthy mind resides in a healthy body"
17
Let S be a stack of size n ≥ 1. Starting with the empty stack, suppose we Push the first n natural numbers in sequence, and then perform n Pop operations. Assume that Push and POP operations take X seconds each, and Y seconds elapse between the end of one such stack operation and the start of the next operation. ... an element of this stack is (A) n(X + Y) (B) 3Y + 2X (C) N(X + Y) - X (D) Y + 2X
18
A priority queue $Q$ is used to implement a stack that stores characters. PUSH (C) is implemented as INSERT $(Q, C, K)$ where $K$ is an appropriate integer key chosen by the implementation. POP is implemented as DELETEMIN$(Q)$. For a sequence of operations, the keys chosen are in non-increasing order non-decreasing order strictly increasing order strictly decreasing order
19
main () { struct xx { int x = 3; char name[] = "hello"; }; struct xx *s; printf("%d", s->x); printf("%s", s->name); } The output is : 3hello 104ello 104hello Compiler error
20
A circularly linked list is used to represent a Queue. A single variable pp is used to access the Queue. To which node should pp point such that both the operations are EnQueue and DeQueue enQueue deQueue can be performed in constant time? rear node front node not possible with a single pointer node next to front What does "constant time" means...(last words of the question).?
21
Consider the $B^+$ tree in the adjoining figure, where each node has at most two keys and three links. Keys $K15$ and then $K25$ are inserted into this tree in that order. Exactly how many of the following nodes (disregarding the links) will be present in the tree after the two insertions? $1$ $2$ $3$ $4$
22
23
.WHAT IS TRIPLES????
24
Consider the following ER diagram: If A has 100 entities, B has 1000 entities, and C has 10 entities, what is the maximum number of triples of entities that could be in the relationship set for R?
25
Consider the following F.D. ab -> cd ; e->c ; b->ef Which options show the relations normalized to 3NF of R(A,B,C,D,E,F) 1) R(A,B,C,D) , R(C,E) , R(E,F,B) 2) R(A,B,D) , R(E,C) , R(B,E,F) 3) R(A,B,C,D) , R(C,E) , R(B,E,F) 4) R(A,B,C,D,E,F) , R(E,C) , R(B,E,F) Ans is C
26
R(A,B,C,D) is a relation. Which of the following does not have a lossless join, dependency preserving BCNF decomposition? a)A->B, B->CD b)A->B, B->C, C->D c) AB->C, C->AD d)A ->BCD Plz explain as well...!!!!