Time Left - 20:00 mins

GATE 2018 Mini Mock 4 (full syllabus)

Attempt now to get your rank among 670 students!

Question 1

Consider the following declaration
main()
{
int i = 2; n =3;
if( i < 5)
{
for( ; n <=4; n++)
{
printf(“%d”,n);
}
}
}
Considering the complexity for the condition is O(2)
What will be complexity for above code

Question 2

Consider the following LL(1) parsing table

Which of the following string generates syntax error by the LL(1) parser with start symbol ‘E’?

Question 3

A network is determined by the subnet ID 134.96.51.64 and a 26 bit net mask. How many hosts are addressable in the provided network?

Question 4

Consider a machine with 10 ns clock and it takes 4 clock cycle per ALU instruction, 5 clock cycle per branch instruction, 6 clock cycle memory instruction. There exists 40% ALU instruction, 20% branch instruction, and 40% memory instruction. What is speedup  of pipeline system if overhead is 2 ns ?

Question 5

Trace the output of the code snippet below:
main()
{
int i,j,k, x =0;
for(i=0; i < 4; ++i)
for(j=0; j < i; ++j)
{
  Switch( i + j – 1)
  {
     case – 1 :
     case 0 : x + = 1;
     break;
     case 1 :
     case 2 :
     case 3 : x + = 2;
     default : x + = 3;
   }
     printf(“%d”,x);
}
     printf(“%d”,x);
}

Question 6

Which is the correct order, if all six clauses given below appears in a query

Question 7

The is numerically not equivalent to

Question 8

Consider the following arguments
7.JPG
Which of the following argument is a conclusion?

Question 9

Consider six process P1, P2, . . . P6 and 4 resources R1, R2, R3 and R4. Consider the following order of resource requests and allocations among the processes and resources:
P1 requests R1, R1 is assigned to P2, P3 requests R1,
P3 requests R2, P2 requests R2, R2 is assigned to P5,
P4 requests R1, R3 is assigned to P6, P5 requests R3,
P4 requests R4, R4 is assigned to P2 and P6 requests R4.
Find the possible order of processes in which they can satisfy the requests.

Question 10

The transition diagram for a TM is shown below:

Here: B Blank
X, Y: tape alphabets
R Move right
L Move left
Which of the following strings can be simulated by the above TM

Question 11

In how many ways can seat 11 men and 8 women in a row if all the men sit together and all the women sit together.

Question 12

Choose the most appropriate equation for the function drawn as thick line, in the plot below.

Question 13

Computers were invented for performing only high-end useful computations. However, it is no understatement that they have taken over our world today. The internet, for example, is ubiquitous. Many believe that the internet itself is an unintended consequence of the original invention with the advent of mobile computing on our phones, a whole new dimension is now enabled. One is left wondering if all these developments are good or more importantly, required.
Which of the statement(s) below is/are logically valid and can be inferred from the above paragraph?
(i) The author believes that computers are not good for us
(ii) Mobile computers and the internet are both intended inventions

Question 14

Which of the options given below should replace the part of sentence written in BOLD so as to get a meaningful and grammatically correct sentence.
We had not only helped them with money but also with new machinery and raw material.

Question 15

Which of the given option is most appropriate in the context of the word in bold letters in the given sentence.

The reason there is no exodus towards banks in general for new project funding is their relatively less experience in project appraisal.

  • 670 attempts
  • 7 upvotes
  • 7 comments
Nov 1GATE & PSU CS