GATE 2018 Mini Mock 4 (full syllabus)
Attempt now to get your rank among 670 students!
Question 1
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
Which of the following string generates syntax error by the LL(1) parser with start symbol ‘E’?
Question 3
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
Question 7
Question 8
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
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
Question 12
Choose the most appropriate equation for the function drawn as thick line, in the plot below.
Question 13
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
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
Tags :
GATE & PSU CSMock Tests