The Gateway to Computer Science Excellence
For all GATE CSE Questions
Toggle navigation
GATE Overflow
Facebook Login
or
Email or Username
Password
Remember
Login
Register

I forgot my password
Activity
Questions
Unanswered
Tags
Subjects
Users
Ask
Prev
Blogs
New Blog
Exams
First time here? Checkout the
FAQ
!
x
×
Close
Use the google search bar on side panel. It searches through all previous GATE/other questions. For hardcopy of previous year questions please see
here
Recent activity by Debashish Deka
User Debashish Deka
Wall
Recent activity
All questions
All answers
Exams Taken
All Blogs
User Debashish Deka
Wall
Recent activity
All questions
All answers
Exams Taken
All Blogs
0
answers
1
Find correct statements
Find correct statements: The read system call to fetch data from a file always blocks the invoking process. During filesystem operations, if the file system implementation ensures that changes to data blocks of a file are flushed to disk before changes to ... interrupts on its CPU core for the duration that the spinlock is held, in both single core and multi core systems.
asked
Jan 13
in
Operating System

37
views
operatingsystem
1
answer
2
TLB hit ration and memory lookup time
Consider a system where TLB lookup time is $25$ ns and memory access time is $200$ ns, respectively. Assuming a virtual address space of $2$ KB, page size of $32$ bytes, and a PTE size of $2$ bytes, what is the minimum TLB hit ratio that results in an average v2p (virtual to physical) translation latency of $185$ ns?
asked
Jan 13
in
Operating System

38
views
tlb
hitratio
0
answers
3
process state in operating system
Consider a process P1 that is executing on a Linuxlike OS on a single core system. When P1 is executing, a disk interrupt occurs, causing P1 to go to kernel mode to service that interrupt. The interrupt delivers all the disk blocks that unblock a ... user mode of P1. At this point in time, what are the states (ready/running/blocked) of processes P1 and P2 ?
asked
Jan 13
in
Operating System

35
views
operatingsystem
process
0
answers
4
fork and exec
what is the output of the following program? int ret = fork(); if(ret == 0) { exec(some_binary); // this call fails printf("child "); }else { wait(); printf("parent\n"); } Runtime Error child parent child parent
asked
Jan 13
in
Operating System

32
views
fork
operatingsystem
4
answers
5
GATE200682
Consider the diagram shown below where a number of LANs are connected by (transparent) bridges. In order to avoid packets looping through circuits in the graph, the bridges organize themselves in a spanning tree. First, the root bridge is identified as the bridge with the least serial number. Next, the root ... $\text{B1, B5, B2, B3, B4}$ $\text{B1, B3, B4, B5, B2}$
answer edited
Nov 9, 2018
in
Computer Networks

6.1k
views
gate2006
computernetworks
bridges
normal
4
answers
6
TIFR2017A15
Let $T(a, b)$ be the function with two arguments (both nonnegative integral powers of 2) defined by the following reccurence: $ T(a, b) = T \biggl( \frac{a}{2}, b \biggl) +T\biggl( a, \frac{b}{2} \biggl) \quad \quad \text{ if } a, b \geq 2$ ... $\begin{pmatrix} r+s \\ r \end{pmatrix}$ $2^{rs}$ if $r \geq s$, otherwise $2^{sr}$
answer selected
Sep 26, 2018
in
Algorithms

333
views
tifr2017
algorithms
recurrence
0
answers
7
SpinLock in the kernel Mode
Consider a process in kernel mode that acquires a spinlock. For correct operation, it must disable interrupts on its CPU core for the duration that the spinlock is held, in both single and multicore systems.[True / False]
asked
Sep 15, 2018
in
Operating System

12
views
operatingsystem
0
answers
8
Read system call
The read system call to fetch data from a file always blocks the invoking process.[True / False] [blocking means context switching to another process]
asked
Sep 15, 2018
in
Operating System

5
views
operatingsystem
0
answers
9
Open file table
When a process opens a file that is already being read by another process, the file descriptors in both process will point to the same open file table entry.[True / False]. (open file table ?)
asked
Sep 15, 2018
in
Operating System

13
views
operatingsystem
filesystem
1
answer
10
Fork system call,open file table
The fork system call creates new entries in the open file table for the newly created child process. [True / False] [ what is open file table ? ]
asked
Sep 15, 2018
in
Operating System

80
views
operatingsystem
fork
0
answers
11
Privileged modes
The four privileged modes (Ring 0 to Ring 3 as provided by x86) are the minimum levels of execution modes required for an operating system to operate correctly
asked
Sep 13, 2018
in
Operating System

9
views
operatingsystem
nongate
0
answers
12
System Call
Illustrate the sequence of events/steps for invocation and execution of a system call. Starting from the user level call and back.
asked
Sep 13, 2018
in
Operating System

7
views
operatingsystem
nongate
1
answer
13
Estimate the average time to access data from memory
Estimate the average time to access data from memory with the following information, page fault service time = $2$ ms, memory access time = $200$ ns, $10$ page faults for every $10^6$accesses, TLB hit rate = $50\%$, ... to execute the page fault handler and update the v2p mapping (via possible evictions of other pages, reading from disk etc.)
asked
Sep 13, 2018
in
Operating System

25
views
operatingsystem
nongate
0
answers
14
Interrupt handling
Give an example each for a hardware interrupt, an explicit software interrupt, and an implicit software interrupt, and discuss the possible operations as part of the interrupt handler.
asked
Sep 13, 2018
in
Operating System

15
views
interrupts
operatingsystem
nongate
0
answers
15
System call
A system call operates in a process context. Give an example and explain this statement.
asked
Sep 13, 2018
in
Operating System

10
views
operatingsystem
nongate
1
answer
16
Virtual address space
A onetoone mapping of the entire physical address space to a process's virtual address space is a correct address translation solution. True/False. Explain.
asked
Sep 13, 2018
in
Operating System

55
views
operatingsystem
memorymanagement
nongate
1
answer
17
Page Table
A page table based translation will always consume less memory to store translation metadata, than a segmentation based solution. True/False. Explain.
asked
Sep 13, 2018
in
Operating System

48
views
memorymanagement
pagetable
operatingsystem
nongate
3
answers
18
GATE200581b
double foo(int n) { int i; double sum; if(n == 0) { return 1.0; } else { sum = 0.0; for(i = 0; i < n; i++) { sum += foo(i); } return sum; } } Suppose we modify the above function $foo()$ ... the time complexity for function $foo()$ is significantly reduced. The space complexity of the modified function would be: $O(1)$ $O(n)$ $O(n^2)$ $n!$
commented
Sep 12, 2018
in
Programming

2k
views
gate2005
programming
recursion
normal
0
answers
19
Context Switch : kernel stackuser stack
Consider the following events that happen during a context switch of process $P$ to (user mode of) process $Q$, triggered by a timer interrupt that occurred when $P$ was executing in a Unix like operating system. Arrange the events in the chronological ... the kernel address space of $Q$ to the user address space of $Q$ (E) The OS scheduler code is invoked.
commented
Aug 30, 2018
in
Computer Networks

65
views
operatingsystem
iitb
0
answers
20
Wireless network media access protocol : RTS CTS and its problems
Four wireless nodes are placed on a straight line (see Figure $1$). Let $D(i, j)$ denote the distance between nodes $i$ and $j$. Each node has a circular communication range of $r = 1.5R$. This means that a ... $a$. Explain why this is true. Make any reasonable assumptions and state them clearly. (A rough explanation will do.)
commented
Aug 30, 2018
in
Computer Networks

42
views
computernetworks
iitb
0
answers
21
Medium access in shared media and thoughtput
Consider a scenario in which $\textbf{n}$ hosts share the same medium. The medium has bandwidth (max. data rate) $c$. Time is divided into slots of duration $T$ ... varying $p$)? Interpret your results. (c) What is the limit of maximum throughput as $n \rightarrow \infty$ ? Interpret your results.
asked
Aug 29, 2018
in
Computer Networks

23
views
computernetworks
iitb
4
answers
22
Counting
Show that, in a grid, the number of paths from $(0,0)$ to $(n,n)$ which does not cross ( it could touch ) the line $x = y$ is \begin{align*} \frac{1}{1+n}\binom{2\cdot n}{n} = \binom{2\cdot n}{n}  \binom{2\cdot n}{n1} \end{align*} After that, show the number of balanced paranthesis strings of length $2n$ is same as the above result.
answer selected
Aug 7, 2018
in
Set Theory & Algebra

107
views
counting
combinatoricsiitb
1
answer
23
Peter Linz Exercise 5.3
Find the contextfree grammar for the following language(n>=0 and m>=0) ? L={an bm : n<=m+3}
answer selected
Jun 30, 2018
in
Theory of Computation

747
views
theoryofcomputation
grammar
2
answers
24
Mission IIT Screening Test
commented
Jun 12, 2018
in
Programming

170
views
programminginc
3
answers
25
c programming
#include<stdio.h> int main() { char *s[] = {"ice","green","cone","please"}; char **ptr[] = {s+3,s+2,s+1,s}; char ***p = ptr; printf("%s\n",**++p); printf("%s\n",**++p + 3); printf( ... %s\n",*p[2]+3); printf("%s\n",p[1][1] + 1); return 0; } Please anyone explain this especially last printf statement.
comment edited
May 3, 2018
in
Programming

130
views
1
answer
26
Set theory
Consider the sets $A_1, A_2, A_3 \dots A_m$. Prove that the number of distinct sets of the form $A_i \oplus A_j$ is at least $m$.
commented
Apr 28, 2018
in
Set Theory & Algebra

57
views
settheory
combinatoricsiitb
0
answers
27
Probability and random variable
Consider the sets $A_1, A_2, A_3 \dots A_m$ each a subset of size $k$ of $\{1,2,3, \dots , n\}$. If in a 2colouring of $\{1,2,3, \dots , n\}$ no set $A_i$ is monochromatic, then show that $ m < 2^{k1}$.
asked
Apr 28, 2018
in
Set Theory & Algebra

71
views
probability
randomvariable
combinatoricsiitb
0
answers
28
Set theory and Induction
Consider the set of all subsets of a set S. A chain is a collection of subsets $P_1 \subset P_2 \subset P_3 \subset P_4 \dots \subset P_k$. A symmetric chain is one which starts at a set of size $i$ and ends at a set of size $n  i$. Prove that the poset has a decomposition into symmetric chains.
asked
Apr 28, 2018
in
Set Theory & Algebra

38
views
settheory
combinatoricsiitb
0
answers
29
Probability and set theory
Consider sets $A_1,A_2,A_3 \text{ to } A_m \text{ where }A_i \subseteq [n] \text{ and } [n] = \{1,2,3, \dots n \}$ such that there are no three distinct sets in the collection with the property $A_i \subset A_j \subset A_k.$ For even $n$, prove that \begin{align*} m ... bound on $m$ : \begin{align*} m \leq \binom{n}{\frac{n}{2}} + \binom{n}{\frac{n}{2}  1} \end{align*}
asked
Apr 27, 2018
in
Set Theory & Algebra

34
views
probability
settheory
combinatoricsiitb
1
answer
30
Set system and linear algebra
We have $m$ sets $A_1,A_2,A_3 \text{ to } A_m$. All $A_i \subseteq [n]$ where $ [n] = \{1,2,3, \dots n \}.$ Given that $A_i = \text{odd number}$ and $A_i \cap A_j = \text{even number }\forall i \neq j$. Show that $m \leq n$.
retagged
Apr 27, 2018
in
Set Theory & Algebra

390
views
sets
linearalgebra
combinatoricsiitb
1
answer
31
Induction
Prove that the number of edges in a graph with exactly one triangle is at most \begin{align*} \frac{\left( n  1 \right )^2}{4} + 2 \end{align*}
asked
Apr 27, 2018
in
Graph Theory

61
views
induction
graphtheory
combinatoricsiitb
0
answers
32
Probability
Prove for a positive integer valued random variable, $X$ , and for positive integers $a < b$ \begin{align*} &P(X \geq b) \leq \left [ \left ( \frac{E(X)}{b} \right )  P(a \leq X < b)\cdot \left ( \frac{a}{b} \right ) \right ] \\ \end{align*}
asked
Apr 27, 2018
in
Probability

33
views
probability
combinatoricsiitb
2
answers
33
GATE199292,xv
Which of the following predicate calculus statements is/are valid? $(\forall (x)) P(x) \vee (\forall(x))Q(x) \implies (\forall (x)) (P(x) \vee Q(x))$ $(\exists (x)) P(x) \wedge (\exists (x))Q(x) \implies (\exists (x)) (P(x) \wedge Q(x))$ ... $(\exists (x)) (P(x) \vee Q(x)) \implies \sim (\forall (x)) P(x) \vee (\exists (x)) Q(x)$
commented
Jan 3, 2018
in
Mathematical Logic

4.2k
views
gate1992
mathematicallogic
normal
firstorderlogic
3
answers
34
Minimum number of comparisons
The minimum number of comparisons required to sort 5 elements is  a) 4 b) 5 c) 6 d) 7
commented
Dec 29, 2017
in
Algorithms

3.8k
views
0
answers
35
Conditional probability
A student $Y$ lives in a place $X$. In $X$ a day can be cloudy with probability $\bf0.02$ uniformly each day. $Y$'s friends may come to his house with probability $\bf0.2$ uniformly in each day irrespective of weather condition. These two events are independent. $Y$ can ... on a particular day ?
edited
Dec 25, 2017
in
Probability

153
views
conditionalprobability
7
answers
36
GATE2007IT83
The head of a hard disk serves requests following the shortest seek time first (SSTF) policy. The head is initially positioned at track number $180$. What is the maximum cardinality of the request set, so that the head changes its direction after servicing every request if the total number of tracks are $2048$ and the head can start from any track? $9$ $10$ $11$ $12$
commented
Dec 24, 2017
in
Operating System

4.6k
views
gate2007it
operatingsystem
diskscheduling
normal
6
answers
37
GATE200583a
Statement for Linked Answer Questions 83a & 83b: Consider the following expression grammar. The semantic rules for expression evaluation are stated next to each grammar production. ... shift over a reduce action It detects shiftreduce conflict, and resolves the conflict in favor of a reduce over a shift action
answer edited
Dec 23, 2017
in
Compiler Design

6k
views
gate2005
compilerdesign
parsing
normal
1
answer
38
C CODING
#include <stdio.h> int main() { float a=5.375; char *p; int i; p = (char*)&a; for(i=0; i<2; i++) printf("%x", (unsigned char)(p[i]^p[3i])); return 0; } Explain in detail
commented
Nov 2, 2017
in
Programming

110
views
1
answer
39
Algo: Time complexity
T(n) = 4T(n/2) + n2.$\sqrt{2}$ In thetha notation?
commented
Oct 18, 2017
in
Algorithms

172
views
timecomplexity
algorithms
asymptoticnotations
2
answers
40
mock test
Considering size of int as 2 Bytes and size of char as 1 Byte what will be the output int main() { int a=300; char *b=(char *)&a; *==b=2; printf("%d",a); return 0; }
commented
Sep 21, 2017
in
Programming

55
views
47,198
questions
51,428
answers
178,320
comments
66,728
users