Ans . C


  1. Explanation :

    TCP (Transmission Control Protocol) and UDP(User Datagram Protocol) are two main transport layer protocols.
    TCP is connection oriented and UDP is connectionless, this makes TCP more reliable than UDP. But UDP is stateless (less overhead), that makes UDP is suitable for purposes where error checking and correction is less important than timely delivery.
    For real time multimedia, timely delivery is more important than correctness. -> UDP
    For file transfer, correctness is necessary. -> TCP
    DNS, timely delivery is more important -> UDP
    Email again same as file transfer -> TCP



GATE CSE Solved papers


Ans .

C


  1. Explanation :

    Router is a network layer device.
    GATE CSE Solved papers
    So every packet passes twice through data link layer of every intermediate router.





Ans .

C


  1. Explanation :

    A database index is clustered if physical records on disk follow the index order.





Ans .

B


  1. Explanation :

    Option A can cause deadlock. Imagine a situation process X has acquired a, process Y has acquired b and process Z has acquired c and d. There is circular wait now.
    Option C can also cause deadlock. Imagine a situation process X has acquired b, process Y has acquired c and process Z has acquired a. There is circular wait now.
    Option D can also cause deadlock. Imagine a situation process X has acquired a and b, process Y has acquired c. X and Y circularly waiting for each other.
    Consider option A) for example here all 3 processes are concurrent so X will get semaphore a, Y will get b and Z will get c, now X is blocked for b, Y is blocked for c, Z gets d and blocked for a. Thus it will lead to deadlock.
    Similarly one can figure out that for B) completion order is Z,X then Y.



  1. For every non-deterministic Turing machine, there exists an equivalent deterministic Turing machine.
  2. Turing recognizable languages are closed under union and complementation.
  3. Turing decidable languages are closed under intersection and complementation.
  4. Turing recognizable languages are closed under union and intersection.


Ans .

C


  1. Explanation :

    A recognizer of a language is a machine that recognizes that language. A decider of a language is a machine that decides that language.
    Both types of machine halt in the Accept state on strings that are in the language
    A Decider also halts if the string is not in the language
    A Recogizer MAY or MAY NOT halt on strings that are not in the language
    On all input:
    A Decider MUST halt (in Accept or Reject state)
    A Recogizer MAY or MAY NOT halt on some strings (Q: Which ones?)
    A language is Turing-decidable (or decidable) if some Turing machine decides it. Aka Recursive Language.
    A language is Turing-recognizable if some Turing machine recognizes it. Aka Recursively Enumerable Language.
    Recursive (Turing Decidable) languages are closed under following Kleene star, concatenation, union, intersection, complement and set difference.
    Recursively enumerable language are closed under Kleene star, concatenation, union, intersection. They are NOT closed under complement or set difference.



  1. The problem of determining whether there exists a cycle in an undirected graph is in P.
  2. The problem of determining whether there exists a cycle in an undirected graph is in NP.
  3. If a problem A is NP-Complete, there exists a non-deterministic polynomial time algorithm to solve A.


Ans .

A


  1. Explanation :

    1 is true because cycle detection can be done in polynomial time using DFS.
    2 is true because P is a subset of NP.
    3 is true because NP complete is also a subset of NP and NP means Non-deterministic Polynomial time solution exists.





Ans .

C


  1. Explanation :

    Time complexity of Bellman-Ford algorithm is O(VE) where V is number of vertices and E is number of edges. For a complete graph with n vertices, V = n, E = O(n^2). So overall time complexity becomes O(n^3)





Ans .

A


  1. Explanation :

    Number of sets in cache = v. So, main memory block j will be mapped to set (j mod v), which will be any one of the cache lines from (j mod v) * k to (j mod v) * k + (k-1). (Associativity plays no role in mapping- k-way associativity means there are k spaces for a block and hence reduces the chances of replacement.)





Ans .

D


  1. Explanation :

    It is a simple De Morgan's laws question.





Ans .

A


  1. Explanation :

    A function is continuous at some point c, Value of f(x) defined for x > c = Value of f(x) defined for x < c = Value of f(x) defined for x = c All values are 2 in option A





Ans .

C


  1. Explanation :

    Q is true: Since the graph is undirected, every edge increases the sum of degrees by 2. P is true: If we consider sum of degrees and subtract all even degrees, we get an even number (because Q is true). So total number of odd degree vertices must be even.





Ans .

C


  1. Explanation :

    A cycle of length 3 can be formed with 3 vertices. There can be total 8C3 ways to pick 3 vertices from 8. The probability that there is an edge between two vertices is 1/2. So expected number of unordered cycles of length 3 = (8C3)*(1/2)^3 = 7





Ans .

A


  1. Explanation :

    Here a binary operation on a set of integers is defined as x \(\oplus\) y = x2 + y2. for Commutativity: x \(\oplus\)y= y \(\oplus\)x.
    LHS=> x \(\oplus\)y= x^2+ y^2
    RHS=> y \(\oplus\) x= y^2+x^2
    LHS = RHS. hence commutative.
    for Associativity: x \(\oplus\) (y \(\oplus\) z) =(x \(\oplus\) y) \(\oplus\) z
    LHS=> x \(\oplus\) (y\(\oplus\) z) = x \(\oplus\) ( y^2+z^2)= x^2+(y^2+z^2)^2
    RHS=> (x \(\oplus\) y) \(\oplus\) z= ( x^2+y^2) \(\oplus\) z=(x^2+y^2)^2+z^2
    So, LHS ? RHS, hence not associative.





Ans .

C


  1. Explanation :

    PR(X < 3) = Pr(x = 0) + Pr(x = 1) + Pr(x = 2) = f(0, 3) + f(1, 3) + f(2, 3) Put \lambda = 3 and k = 0, 1, 2 in the formula of Poisson distribution
    = 17 / (2e3)





Ans .

A


  1. Explanation :

    First of all, you should know the basic properties of determinants before approaching For these kind of problems.
    1) Applying any row or column transformation does not change the determinant
    2) If you interchange any two rows, sign of the determinant will change
    A = | 1 x x^2 |
           | 1 y y^2 |
           | 1 z z^2 |
    To prove option (b)
    => Apply column transformation C2 -> C2+C1
    C3 -> C3+C1
    => det(A) = | 1 x+1 x^2+1 |
                       | 1 y+1 y^2+1 |
                       | 1 z+1 z^2+1 |
    To prove option (c),
    => Apply row transformations R1 -> R1-R2
    R2 -> R2-R3
    => det(A) = | 0 x-y x^2-y^2 |
                        | 0 y-z y^2-z^2 |
                        | 1 z z^2 |
    To prove option (d),
    => Apply row transformations R1 -> R1+R2
    R2 -> R2+R3
    => det(A) = | 2 x+y x^2+y^2 |
                       | 2 y+z y^2+z^2 |
                       | 1 z z^2 |





Ans .

B


  1. Explanation :

    For n bit 2's complement numbers, range of number is -(2^(n-1)) to +(2^(n-1)-1)





Ans .

A


  1. Explanation :

    Since there are more than one outputs and number of outputs is less than inputs, it is a Priority encoder
    V=1 when input is valid and for priority encoder it checks first high bit encountered. Except all are having at least one bit high and 'x' represents the "don't care" as we have found a high bit already. So answer is (A).





Ans .

B


  1. Explanation :

    To sort elements in increasing order, selection sort always picks the maximum element from remaining unsorted array and swaps it with the last element in the remaining array. So the number of swaps, it makes in n-1 which is O(n)





Ans .

C


  1. Explanation :

    To insert an element, we need to search for its place first. The search operation may take O(n) for a skewed tree.





Ans .

A


  1. Explanation :

    L1 L2* U L1* Result of L1 L2* is \phi. {\phi} indicates an empty language. Concatenation of \phi with any other language is \phi. It works as 0 in multiplication. L1* = \phi* which is {\epsilon}. Union of \phi and {\epsilon} is {\epsilon}





Ans .

B


  1. Explanation :

    Given in the question, a grammar with no epsilon- and unit-production (i.e., of type A -> ? and A -> a) .
    Suppose the string is abcd. ( n = 4 )
    We can write the grammar which accepts this string as follows:
    S->aB
    B->bC
    C->cd
    The Right Most Derivation for the above is:
    S -> aB ( Reduction 3 )
    -> abC ( Reduction 2 )
    -> abcd ( Reduction 1 )
    We can see here that no production is for unit or epsilon. Hence 3 reductions here.
    We can get less number of reductions with some other grammar which also does't produce unit or epsilon productions,
    S->abA
    A-> cd
    The Right Most Derivation for the above as:
    S -> abA ( Reduction 2 )
    -> abcd ( Reduction 1 )
    Hence 2 reductions.
    But we are interested in knowing the maximum number of reductions which comes from the 1st grammar. Hence total 3 reductions as maximum, which is ( n 1) as n = 4 here.
    Thus, Option B.





Ans .

B


  1. Explanation :

    The scheduling algorithm works as round robin with quantum time equals to T. After a process's turn comes and it has executed for T units, its waiting time becomes least and its turn comes again after every other process has got the token for T units.





Ans .

C


  1. Explanation :

    The answer can be easily guessed with XML. XML is used for information representation.





Ans .

D


  1. Explanation :

    X adds his digital signature: In order to identify the authentic user, X uses his Private Key to encrypt his signature.
    X then encrypts the whole message with the digital signature: X uses Y's Public Key to encrypt the message so that Y can decipher it when it reaches to him using his private key.
    Message then reaches Y.
    Y then uses his Private key to decrypt the message, and extracts the message and along with the signature.
    But as the signature has been encrypted using X's private key so: Y uses X's Public Key to see the signature if it matches X's actual signature (this step ensures that no one can fake as X and sends a message to Y ).
    Nobody can tamer the message as in order to do that he/she has to first know Y's private key to decipher the message extract the signature and then change the signature and then recreate that using X's private key which is not with him.
    So sequence of operations:
    X's Private Key?Y's public key?Y's Private key?X's public Key.
    Ans is option (D).





Ans .

C


  1. Explanation :

    M = 0 indicates that this packet is the last packet among all fragments of original packet. So the answer is either A or C.
    It is given that HLEN field is 10. Header length is number of 32 bit words. So header length = 10 * 4 = 40
    Also, given that total length = 400.
    Total length indicates total length of the packet including header.
    So, packet length excluding header = 400 - 40 = 360
    Last byte address = 2400 + 360 - 1 = 2759 (Because numbering starts from 0)





Ans .

A


  1. Explanation :

    Answer is "No Change"
    Cohesion refers to the degree to which the elements of a module belong together.
    Coupling is the manner and degree of interdependence between software modules
    Coupling between M1 and M2 = (Number of external links) / (Number of modules)
    = 2/2
    = 1 v Cohesion of a module = (Number of internal links) / (Number of methods)
    Cohesion of M1 = 8/4 = 2
    Cohesion of M2 = 6/3 = 2
    Coupling = 2/2 = 1
    Cohesion of M1 = 6/3 = 2
    Cohesion of M2 = 8/4 = 2





Ans .

C


  1. Explanation :

    purpose here is neither the deadlock should occur nor the binary semaphores be assigned value greater than one.
    A leads to deadlock
    B can increase value of semaphores b/w 1 to n
    D may increase the value of semaphore R and S to 2 in some cases



  1. Cannot be merged since look aheads are different.
  2. Can be merged but will result in S-R conflict.
  3. Can be merged but will result in R-R conflict.
  4. Cannot be merged since goto on c will lead to two different sets.


Ans .

D


  1. Explanation :

    The given two LR(1) set of items are :
    X -> c.X, c/d
    X -> .cX, c/d
    X -> .d, c/d
    and
    X -> c.X, $
    X -> .cX, $
    X -> .d, $
    The symbols/terminals after the comma are Look-Ahead symbols.
    These are the sets of LR(1) ( LR(1) is also called CLR(1) ) items.
    The LALR(1) parser combines those set of LR(1) items which are identical with respect to their 1st component but different with respect to their 2nd component.
    In a production rule of a LR(1) set of items, ( A -> B , c ) , A->B is the 1st component , and the Look-Ahead set of symbols, which is c here, is the second component.
    Now we can see that in the sets given, 1st component of the corresponding production rule is identical in both sets, and they only differ in 2nd component ( i.e. their look-ahead symbols) hence we can combine these sets to make a a single set which would be :
    X -> c.X, c/d/$
    X -> .cX, c/d/$
    X -> .d, c/d/$
    This is done to reduce the total number of parser states.
    Now we can check the statements given.
    Statement 1 : The statement is false, as merging has been done because 2nd components i.e. look-ahead were different.
    Statement 2 : In the merged set, we can't see any Shift-Reduce conflict ( because no reduction even possible, reduction would be possible when a production of form P -> q. is present)
    Statement 3 : In the merged set, we can't see any Reduce-Reduce conflict ( same reason as above, no reduction even possible, so no chances of R-R conflict )
    Statement 4: This statement is also wrong, because goto is carried on Non-Terminals symbols, not on terminal symbols, and c is a terminal symbol.
    Thus, all statements are wrong, hence option D.





Ans .

D


  1. Explanation :

    First is Emptiness for CFG; whether a CFG is empty or not, this problem is decidable.
    Second is everything for CFG; whether a CFG will generate all possible strings (completeness of CFG), this problem is undecidable.
    Third is Regularity for REC; whether language generated by TM is regular is undecidable.
    Fourth is equivalence for regular; whether language generated by DFA and NFA are same is decidable.
    Second and third will be undecidable.
    Hence, option (D) is Correct.





Ans .

All


  1. Explanation :

    In this question marks were given to all as the same code in C/C++ produces undefined behavior. This is because * is not a sequence point in C/C++. The correct code must replace
    return f(x,c) * x;
    with
    res = f(x,c); // ';' forms a sequence point
    //and all side-effects are guaranteed to be completed here
    //-- updation of the x parameter inside f is guaranteed
    //to be reflected in the caller from the next point onwards.
    return res * x;
    In this code, there will be 4 recursive calls with parameters (6,4),(7,3),(8,2) and (9,1). The last call returns 1. But due to pass by reference, x in all the previous functions is now 9. Hence, the value returned by f(p,p) will be 9*9*9*9*1=6561.





Ans .

D


  1. Explanation :

    In order to construct a binary tree from given traversal sequences, one of the traversal sequence must be Inorder. The other traversal sequence can be either Preorder or Postorder. We know that the Inorder traversal of Binary Search Tree is always in ascending order so the Inorder Traversal would be the ascending order of given Preorder traversal i.e 10, 15, 20, 23, 25, 30, 35, 39, 42.Now we have to construct a tree from given Inorder and Preorder traversals.





Ans .

B


  1. Explanation :

    Pipeline will have to be stalled till Ei stage of l4 completes, as Ei stage will tell whether to take branch or not.
    After that l4(WO) and l9(Fi) can go in parallel and later the following instructions.
    So, till l4(Ei) completes : 7 cycles * (10 + 1 ) ns = 77ns
    From l4(WO) or l9(Fi) to l12(WO) : 8 cycles * (10 + 1)ns = 88ns
    Total = 77 + 88 = 165 ns





Ans .

A


  1. Explanation :

    There are three possible operations on queue- Enqueue, Dequeue and MultiDequeue. MultiDequeue is calling Dequeue multiple times based on a global variable k. Since, the queue is initially empty, whatever be the order of these operations, there cannot be more no. of Dequeue operations than Enqueue operations. Hence, the total no. operations will be n only.





Ans .

B


  1. Explanation :

    RAM chip size = 1k x 8[1024 words of 8 bits each]
    RAM to construct =16k x 16
    Number of chips required = (16k x 16)/ ( 1k x 8) = (16 x 2)
    [16 chips vertically with each having 2 chips horizontally]
    So to select one chip out of 16 vertical chips, we need 4 x 16 decoder.
    Available decoder is 2 x 4 decoder
    To be constructed is 4 x 16 decoder
    Hence 4 + 1 = 5 decoders are required.





Ans .

All


  1. Explanation :

    A useful rule: GATE CSE Solved papers
    i.e.; If some property Α is true for all x, then it is equivalent ot say that no x exists such that property a does not hold for it.
    Starting with choices:
    GATE CSE Solved papers
    So, A is not matching with the logical statement in question.
    GATE CSE Solved papers
    Hence matches with the given statement.
    GATE CSE Solved papers
    Hence matches with the given statement.
    GATE CSE Solved papers
    So, D is not matching with the logical statement in question.
    Thus both A and D are not logically equivalent to the given statement. In GATE 2013 marks were given to all for this question





Ans .

D


  1. Explanation :

    F(x) ==> x is my friend
    P(x) ==> x is perfect
    D is the correct answer.
    A. There exist some friends which are not perfect
    B. There are some people who are not my friend and are perfect
    C. There exist some people who are not my friend and are not perfect.
    D. There doesn't exist any person who is my friend and perfect





Ans .

A


  1. Explanation :

    P only
    because by taking a simple graph of 4 vertices(i.e planar graph)(take a 2 regular graph) and we can some to know it's planar : option C eliminated , but tree for tree is not possible as it seems to be a cycle : option D eliminated. also planar doesn't seem possible , hence possible answer is option A.





Ans .

D


  1. Explanation :

    MBR - Memory Buffer Register ( that stores the data being transferred to and from the immediate access store)
    MAR - Memory Address Register ( that holds the memory location of data that needs to be accessed.)
    PC - Program Counter ( It contains the address of the instruction being executed at the current time )
    The 1st instruction places the value of PC into MBR
    The 2nd instruction places an address X into MAR.
    The 3rd instruction places an address Y into PC.
    The 4th instruction places the value of MBR ( which was the old PC value) into Memory.
    Now it can be seen from the 1st and the 4th instructions, that the control flow was not sequential and the value of PC was stored in the memory, so that the control can again come back to the address where it left the execution.
    This behavior is seen in the case of interrupt handling. And here X can be the address of the location in the memory which contains the beginning address of Interrupt service routine.
    And Y can be the beginning address of Interrupt service routine.
    In case of conditional branch (as for option C ) only PC is updated with the target address and there is no need to store the old PC value into the memory.
    And in the case of Instruction fetch and operand fetch ( as for option A and B), PC value is not stored anywhere else.
    Hence option D.





Ans .


  1. Explanation :

    42797KB will take 85512 sectors (42797*1024 bytes / 512 bytes)
    Since there are 64 sectors per surface, 85512/64 = 1337.406 sectors are required, so we take 1338 sectors these sectors are distributed among 16 surfaces, so 1338/16 = 83.58 cylinders will be required.
    So the final ans will be 84+1200 = 1284.
    one more fact to be noted is that the file occupies 83.58 cylinders, but the 0.58 cannot be accommodated in the first one (the file storage starts from ). Hence, the file will be extended to 194 (85594-85400) more bytes of cylinder 1284.





Ans .

C


  1. Explanation :

    heap sort of x element takes xlogx time.
    So, if x = logn / loglogn time required is coming out to be :
    logn- (logn*logloglogn / loglogn )
    Second term vanishes when n is very large.





Ans .

B


  1. Explanation :

    Here we have to tell the value of k returned not the time complexity.
    for (i = n/2; i <= n; i++)
    for (j = 2; j <= n; j = j * 2)
    k = k + n/2;
    return k;
    The outer loop runs n/2 times
    The inner loop runs logn times.(2^k = n => k = logn).
    Now looking at the value of k in inner loop, n is added to k, logn times as the inner loop is running logn times.
    Therefore the value of k after running the inner loop one time is n*logn.
    Therefore total time complexity is inner multiplied with outer loop complexity which (n for outer and nlogn for inner) n^2logn.





Ans .

D


  1. Explanation :

    (D) is false.
    L1 is regular, so its complement would also be regular.
    L1 is a regular language of the form 0^* 1^* 0^*. L2 on the other hand is a CFL as it can be derived from the following CFG
    L2 = { 0^p 1^q 0^r | p,q,r>0 And p notEqualTo r }
    S -> AC|CA
    C -> 0C0|B
    A -> 0A|0
    B -> 1B|epsilon
    If coming up with a CFG for L2 is difficult, one can intuitively see that by reducing it to a simpler problem. L2 is very similar to a known CFL L3 = { a^m b^l | m notEqualTo n }
    (A) L2 is context free, which is true [CORRECT]
    (B) L1 intersection L2 is context free, which is again true because L1 is a regular language and L2 is a CFL. RL union CFL is always a CFL. Hence [CORRECT]
    (C) Complement of L2 is recursive, which is true due to the fact that complement of a CFL is CSL for sure (Context sensitive language), which in turn (CSL) is a subset of recursive languages. Hence [CORRECT]
    (D) Complement of L1 is context free but not regular, which is false due to closure laws of regular languages. Complement of a RL is always a RL. Hence [INCORRECT]





Ans .

D


  1. Explanation :

    is true. L(A) is regular, its complement would also be regular. A regular language is also context free.
    2 is true.
    3 is false, the DFA can be minimized to two states. Where the second state is final state and we reach second state after a 0.
    4 is clearly false as the DFA accepts a single 0.





Ans .

D


  1. Explanation :

    Since initial value of semaphore is 2, two processes can enter critical section at a time- this is bad and we can see why.
    Say, X and Y be the processes.X increments x by 1 and Z decrements x by 2. Now, Z stores back and after this X stores back. So, final value of x is 1 and not -1 and two Signal operations make the semaphore value 2 again. So, now W and Z can also execute like this and the value of x can be 2 which is the maximum possible in any order of execution of the processes. (If the semaphore is initialized to 1, processed would execute correctly and we get the final value of x as -2.)
    Option (D) is the correct answer.





Ans .

A


  1. Explanation :

    Option A: This is a SQL query expression. It first perform a cross product of Students and Registration, then WHERE clause only keeps those rows in the cross product set where the student is registered for course no 107, and percentage is > 90. Then select distinct statement gives the distinct names of those students as the result set.
    Option B: This is a relational algebra expression. It first perform a NATURAL JOIN of Students and Registration (NATURAL JOIN implicitly joins on the basis of common attribute, which here is rollno ), then the select operation( sigma) keeps only those rows where the student is registered for courseno 107, and percentage is > 90. And then the projection operation (pi) projects only distinct student names from the set.
    Note: Projection operation (pi) always gives the distinct result.
    Option C: This is a Tuple Relational Calculus (TRC) language expression, It is not a procedural language (i.e. it only tells "what to do", not "how to do"). It just represents a declarative mathematical expression.
    Here T is a Tuple variable.
    From left to right, it can be read like this, "It is a set of tuples T, where, there exists a tuple S in Relation Students, and there exist a tuple R in relation Registration, such that S.rollno = R.rollno AND R.couseno = 107 AND R.percent > 90 AND T.sname = S.sname". And the schema of this result is (sname), i.e. each tuple T will contain only student name, because only T.sname has been defined in the expression.
    As TRC is a mathematical expression, hence it is expected to give only distinct result set.
    Option D: This is a Domain Relational Calculus (DRC) language expression. This is also not procedural. Here SN is a Domain Variable. It can be read from left to right like this "The set of domain variable SN, where, there exist a domain variable SR , and a domain variable Rp, such that, SN and SR domain variables is in relation Students and SR,107,RP is a domain variables set in relation Registration, AND RP > 90"
    Above, SN represents sname domain attribute in Students relation, SR represents rollno domain attribute in Students relation, and RP represents percentage domain attribute in Registration relation.
    The schema for the result set is (SN), i.e. only student name.
    As DRC is a mathematical expression, hence it is expected to give only distinct result set.





Ans .

B


  1. Explanation :

    Data should be transmitted at the rate of 500 Mbps.
    Transmission Time >= 2*Propagation Time
    => 10000/(500*1000000) lenght = 2km (max)
    so, answer will be: (B) 2km





Ans .

C


  1. Explanation :

    The test cases 3 and 4 are the only cases that capture the flaw. The code doesn't work properly when an old character is replaced by a new character and the new character is again replaced by another new character. This doesn't happen in test cases (1) and (2), it happens only in cases (3) and (4).





Ans .

B


  1. Explanation :

    The test cases 3 and 4 are the only cases that capture the flaw. The code doesn't work properly when an old character is replaced by a new character and the new character is again replaced by another new character. This doesn't happen in test cases (1) and (2), it happens only in cases (3) and (4).





Ans .

B


  1. Explanation :

    Here, we are told not to do code motion. So, we start with 3 registers
    c = a + b; //a, c in register
    d = c * a; //a, c, d in register
    e = c + a; //a, c, e in register, d spilled.
    So, now we try with 4 registers
    c = a + b; //a, c in register
    d = c * a; //a, c, d in register
    e = c + a; //a, c, d, e in register
    x = c * c; //a, x, d, e in register
    if (x > a) {
    y = a * a;
    }
    else {
    d = d * d;
    e = e * e;
    }
    No spilling. So, 4 is the minimum number of registers needed for avoiding spilling.





Ans .

B


  1. Explanation :

    r1......r2
    a.......b......c = a + b
    a.......c......x = c * c
    a.......x......but we will have to store c in mem as we don't know if x > a ................. or not
    y.......x......y = a * a
    choosing the best case of x > a , min spills = 1





Ans .

B


  1. Explanation :

    Here we can see that D is not part of any FD's , hence D must be part of the candidate key.
    Now D+ ={ D}.
    Hence we have to add A,B,C,E,F,G,H to D and check which of them are Candidate keys of size 2.
    We can proceed as
    AD+= {A,B,C,D,E,F,G,H}
    Similarly we see BD+ , ED+ and FD+ also gives us all the attributes.Hence AD,BD,ED,FD are definitely the candidate keys.
    But CD+ , GD+ and HD+ doesnt give all the attributes hence CD,GD and HD are not candidate keys.
    Now we need to check the candidate keys of size 3 . Since AD , BD, ED, FD are all candidate keys hence we can't find candidate keys by adding elements to them as they will give us superkeys as they are already minimal. Hence we have to proceed with CD,GD and HD.
    Also we can't add any of {A,B,E,F} to CD, GD, HD as they will again give us superset of {AD,BD,ED,FD} .
    Hence we can only add among {C,G,H} to CD, GD, HD.
    Adding C to GD and HD we get GCD , HCD. Taking closure and we will see they are not candidate keys.
    Adding H to GD we get GHD which is also not a candidate key.(no more options with 3 attributes possible)
    Now we need to check for candidate keys with 4 attributes . Since only remaining options are CGH and we have to add D only possible key of size 4 is CGHD whose closure also doesn't give us all of the attributes in the relation(All possible options covered)
    Hence no of candidate keys are 4 : AD,BD,ED,FD.





Ans .

A


  1. Explanation :

    The table is not in 2nd Normal Form as the non-prime attributes are dependent on subsets of candidate keys.
    The candidate keys are AD, BD, ED and FD. In all of the following FDs, the non-prime attributes are dependent on a partial candidate key.
    A -> BC
    B -> CFH
    F -> EG





Ans .

A


  1. Explanation :

    Let the page size be x.
    Since virtual address is 46 bits, we have total number of pages =246x
    We should have an entry for each page in last level page table which here is T3. So,
    number of entries in T3 (sum of entries across all possible T3 tables) =246 / x
    Each entry takes 32 bits = 4 bytes. So, total size of T3 tables =246/x * 4 = 2 48 / x bytes
    Now, no. of T3 tables will be Total size of T3 tables/page table size and for each of these page tables, we must have a T2 entry. Taking T3 size as page size, no. of entries across all T2 tables =(248 / x) / x = 248 / x 2
    Now, no. of T2 tables (assuming T2 size as pagesize) = 248/ x2 * 4 bytes = 250 / x 2 / x= 250 / x3.
    Now, for each of these page table, we must have an entry in T1. So, number of entries in T1
    =250 / x 3
    And size of T1 =250 / x3 * 4 = 252 / x3
    Given in question, size of T1 is page size which we took as x. So,
    x=252/ x 3
    x4=252
    x=213
    =8KB





Ans .

C


  1. Explanation :

    Can it be written this way:
    PA bits - ( cache indexing + cache offset + page offset) = page color bits
    32 - (10 + 6 + 13) = 3
    Thus 23 = 8 colors





Ans .

C


  1. Explanation :

    The correct sentence is "She is a European."
    'an' applies to those words which get pronounced with a, e, i, o, u.
    Here pronunciation is "Yuropean" ( E-silent; has a "Y" sound) , similar to ' a University'.
    Hence a European.





Ans .

C


  1. Explanation :

    This is a decreasing arithmetic progression with difference as 2. The series is 44, 42, 40.... 0, -2, -4...
    The sum would be maximum if we consider the series till 0 or 2. So sum would be 506 using the AP Sum formula





Ans .

A


  1. Explanation :

    In conditional sentences if your conditional sentence (if i ...) is in past perfect then in resultant sentence 'would have' will be used.
    If i had extra clothes , i would have donated them.
    When conditional sentences are imaginary sentences like if i were a cricketer.....then in resultant sentences we have to use 'would'.





Ans .

B


  1. Explanation :

    Nadir means below
    1. Astronomy A point on the celestial sphere directly below the observer, diametrically opposite the zenith.
    2. The lowest point: the nadir of their fortunes.





Ans .

A


  1. Explanation :

    Diffuseness means to spreading widely.





Ans .

B


  1. Explanation :

    Cost is proportional to wages per day and number of hours.
    Wages are increased by 1/5 and working hours are decreased by 1/24.
    So the cost becomes (current cost)*(1+1/5)*(1-/24) = 13200*(6/5)*(23/24) = 15180





Ans .


  1. Explanation :

    None of A, B and C make sense.
    Only option D "No adversity justifies giving up hope" is related to the given information.





Ans .

C


  1. Explanation :

    Let total distance be D
    Total Time = D(1/2*60 + 1/4*30 + 1/4*10) = D/24
    Average Speed = Total distance / Total time = 24





Ans .

B


  1. Explanation :

    The Series can be re-written as
    (v2-v1)/(v2+v1)(v2-v1) + (v3-v2)/(v2+v2)(v3-v2) + .....
    which simplifies to (v2-v1) + (v3-v2) + ..... (v81-v80)
    which again simplifies to
    v81 - v1
    which is 8





Ans .

D


  1. Explanation :

    There are total 90 two digit numbers, out of them 13 are divisible by 7, these are 14, 21, 28, 35, 42, 49, 56, 63, 70, 77, 84, 91, 98.
    Therefore, probability that selected number is not divisible by 7 = 1 - 13/90 = 77/90.
    So, option (D) is true.