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

I forgot my password
All Activity
Questions
Unanswered
Tags
Subjects
Users
Ask
Previous
Blogs
New Blog
Exam Category
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.
Recent activity by nikunj
User nikunj
Wall
Recent activity
All questions
All answers
Exams Taken
All Blogs
User nikunj
Wall
Recent activity
All questions
All answers
Exams Taken
All Blogs
5
answers
1
#Regular Expression
The regular expression 0*(10*)* denotes the same set as (A) (1*0)*1* (B) 0 + (0 + 10)* (C) (0 + 1)* 10(0 + 1)* (D) none of these
commented
Sep 16
in
Theory of Computation

368
views
theoryofcomputation
regularexpressions
1
answer
2
Stack
How many permutations can be obtained in the output using a stack assuming that the input 1,2,3,4,5,6 such that 3 will be popped out from stack at 3rd position ?
commented
Sep 14
in
Programming

199
views
stack
datastructure
1
answer
3
Dining philosophers problem
In dining philosophers Algorithm the minimum number of forks or chopsticks to avoid deadlock is (assume there are 5 philosophers) a. 5 b. 6 c. 10 d. None of these
commented
Sep 13
in
Operating System

209
views
operatingsystem
2
answers
4
Finite Automata to Regular Expression.Can this be solved further?
answered
Sep 13
in
Theory of Computation

149
views
finiteautomata
regularexpressions
theoryofcomputation
4
answers
5
GATE1999_20
(a) A certain processor provides a 'test and set' instruction that is used as follows: TSET register, flag This instruction atomically copies flag to register and sets flag to 1. Give pseudocode for implementing the entry and exit code ... item; Forever; Show that in this solution it is possible that both the processes are sleeping at the same time.
commented
Sep 13
in
Operating System

593
views
gate1999
operatingsystem
processsynchronization
normal
2
answers
6
GATE199825a
Free disk space can be used to keep track of using a free list or a bit map. Disk addresses require $d$ bits. For a disk with $B$ blocks, $F$ of which are free, state the condition under which the free list uses less space than the bit map.
commented
Sep 13
in
Operating System

584
views
gate1998
operatingsystem
disks
descriptive
2
answers
7
GATE199212a
Draw the precedence graph for the concurrent program given below S1 parbegin begin S2:S4 end; begin S3; parbegin S5; begin S6:S8 end parend end; S7 parend; S9
commented
Sep 13
in
Operating System

448
views
gate1992
operatingsystem
normal
concurrency
precedencegraph
1
answer
8
GATE19902iii
Match the pairs in the following questions: (a) Critical region (p) Hoare's monitor (b) Wait/Signal (q) Mutual exclusion (c) Working Set (r) Principle of locality (d) Deadlock (s) Circular Wait
commented
Sep 12
in
Operating System

313
views
matchthefollowing
gate1990
operatingsystem
processsynchronization
2
answers
9
GATE2004IT62
A disk has 200 tracks (numbered 0 through 199). At a given time, it was servicing the request of reading data from track 120, and at the previous request, service was for track 90. The pending requests (in order of their arrival) are for track numbers. ... SSTF(Shortest Seek Time First) and FCFS (First Come Fist Serve)? 2 and 3 3 and 3 3 and 4 4 and 4
commented
Sep 12
in
Operating System

1.2k
views
gate2004it
operatingsystem
diskscheduling
normal
3
answers
10
GATE2004IT67
In a particular Unix OS, each data block is of size 1024 bytes, each node has 10 direct data block addresses and three additional addresses: one for single indirect block, one for double indirect block and one for triple indirect block. Also, each ... of the following is approximately the maximum size of a file in the file system? 512 MB 2 GB 8 GB 16 GB
commented
Sep 12
in
Operating System

983
views
gate2004it
operatingsystem
filesystem
normal
1
answer
11
GATE2008IT52
C program is given below: # include <stdio.h> int main () { int i, j; char a [2] [3] = {{'a', 'b', 'c'}, {'d', 'e', 'f'}}; char b [3] [2]; char *p = *b; for (i = 0; i < 2; i++) { for (j = 0; j < 3; j++) { *(p + 2*j ... ; } } } What should be the contents of the array b at the end of the program? a b c d e f a d b e c f a c e b d f a e d c b f
commented
Sep 11
in
Programming

857
views
gate2008it
programming
programminginc
normal
7
answers
12
GATE200933
The enter_CS() and leave_CS() functions to implement critical section of a process are realized using testandset instruction as follows: void enter_CS(X) { while(testandset(X)); } void leave_CS(X) { X = 0; } In the above solution, X is a ... process can enter CS at the same time Which of the above statements are TRUE? I only I and II II and III IV only
answered
Sep 10
in
Operating System

2.4k
views
gate2009
operatingsystem
processsynchronization
normal
2
answers
13
GATE200931
Consider a disk system with 100 cylinders. The requests to access the cylinders occur in following sequence: 4, 34, 10, 7, 19, 73, 2, 15, 6, 20 Assuming that the head is currently at cylinder 50, what is the time taken to satisfy all ... 1ms to move from one cylinder to adjacent one and shortest seek time first policy is used? 95 ms 119 ms 233 ms 276 ms
commented
Sep 10
in
Operating System

935
views
gate2009
operatingsystem
diskscheduling
normal
4
answers
14
GATE20012.20
Which of the following does not interrupt a running process? A device Timer Scheduler process Power failure
comment edited
Sep 9
in
Operating System

2k
views
gate2001
operatingsystem
easy
process
3
answers
15
GATE200378
A processor uses 2level page tables for virtual to physical address translation. Page tables for both levels are stored in the main memory. Virtual and physical addresses are both 32 bits wide. The memory is byte addressable. For virtual to physical address ... to access a virtual address is approximately (to the nearest 0.5 ns) 1.5 ns 2 ns 3 ns 4 ns
commented
Sep 9
in
Operating System

5.1k
views
gate2003
operatingsystem
normal
virtualmemory
1
answer
16
GATE200377
A uniprocessor computer system only has two processes, both of which alternate 10 ms CPU bursts with 90 ms I/O bursts. Both the processes were created at nearly the same time. The I/O of both processes can proceed ... scheduling Static priority scheduling with different priorities for the two processes Round robin scheduling with a time quantum of 5 ms
commented
Sep 9
in
Operating System

2.2k
views
gate2003
operatingsystem
processschedule
normal
2
answers
17
GATE20089
Which of the following is true for the language $$\left\{ a^p \mid p \text{ is a prime } \right \}?$$ It is not accepted by a Turing Machine It is regular but not contextfree It is contextfree but not regular It is neither regular nor contextfree, but accepted by a Turing machine
commented
Sep 7
in
Theory of Computation

708
views
gate2008
theoryofcomputation
easy
identifyclasslanguage
3
answers
18
GATE2014235
Let $\langle M \rangle$ be the encoding of a Turing machine as a string over $\Sigma=\left\{0,1\right\}$. Let $$L=\left\{\langle M \rangle \mid M \text{ is a Turing machine}\\\ ... .$$ Then $L$ is decidable and recursively enumerable undecidable but recursively enumerable undecidable and not recursively enumerable decidable but not recursively enumerable
answered
Sep 7
in
Theory of Computation

3.1k
views
gate20142
theoryofcomputation
turingmachine
normal
4
answers
19
GATE2016244
Consider the following languages. $L_{1} = \left\{\left\langle M \right\rangle \mid M \text{ takes at least 2016 steps on some input} \right\}$, $L_{2} = \left\{\left\langle M \right\rangle \mid M \text { takes at least 2016 steps on all inputs ... not recursive $L_{1}, L_{2}$ are recursive and $L_{3}$ is not recursive $L_{1}, L_{2}, L_{3}$ are recursive
commented
Sep 7
in
Theory of Computation

4.2k
views
gate20162
theoryofcomputation
turingmachine
1
answer
20
GATE19872m
State whether the following statements are TRUE or FALSE: The problem as to whether a Turing machine $M$ accepts input $w$ is undecidable.
commented
Sep 7
in
Theory of Computation

181
views
gate1987
theoryofcomputation
turingmachine
decidability
3
answers
21
GATE19872h
State whether the following statements are TRUE or FALSE: Regularity is preserved under the operation of string reversal.
answered
Sep 7
in
Theory of Computation

137
views
gate1987
regularlanguages
theoryofcomputation
1
answer
22
CFL or not
L={ wε(a+b)*  #a  #b <=10 } CFL or Reg ?
commented
Sep 6
in
Theory of Computation

46
views
theoryofcomputation
2
answers
23
Regular or CFL
L={w length of w is odd and its middle symbol is 0, wε{0,1}* } Reg or CFL?
answered
Sep 6
in
Theory of Computation

70
views
theoryofcomputation
6
answers
24
GATE200350
Consider the following deterministic finite state automaton M. Let S denote the set of seven bit binary strings in which the first, the fourth, and the last bits are 1. The number of strings in S that are accepted by M is 1 5 7 8
commented
Sep 5
in
Theory of Computation

1.3k
views
gate2003
theoryofcomputation
finiteautomata
normal
3
answers
25
GATE2014115
Which one of the following is TRUE? The language $L = \left\{a^nb^n \mid n \geq 0\right\}$ is regular. The language $L = \left\{a^n \mid n \text{ is prime }\right\}$ is regular. The language $L$= $\left\{ w \mid w \text{ has } 3k+1 \ ... regular. The language $L = \left\{ww \mid w \in \Sigma^* \text{ with } \Sigma = \left\{0,1\right\}\right\}$ is regular.
commented
Sep 5
in
Theory of Computation

764
views
gate20141
theoryofcomputation
regularlanguages
normal
0
answers
26
Correct Approach or attitude while solving C programming Gate question
asked
Sep 2
in
Study Resources

51
views
programminginc
selfdoubt
2
answers
27
GATE1993_26
A stack is used to pass parameters to procedures in a procedure call. If a procedure $P$ has two parameters as described in procedure definition: procedure P (var x :integer; y: integer); and if $P$ is called by ; $P(a, b)$ State ... and $b$ In the generated code for the body of procedure $P$, how will the addressing of formal parameters $x$ and $y$ differ?
commented
Sep 1
in
Programming

306
views
gate1993
programming
parameterpassing
normal
2
answers
28
PDA =FA+1stack??
we know that PDA = FA+1stack so why we use the stack data structure in PDA, we have much more data structure like linked liste,queue, array or tree/hashing???
answered
Sep 1
in
Theory of Computation

40
views
pushdownautomata
1
answer
29
GATE20022.8
Consider the following declaration of a twodimensional array in C: char a[100][100]; Assuming that the main memory is byteaddressable and that the array is stored starting from memory address 0, the address of a [40][50] is 4040 4050 5040 5050
commented
Sep 1
in
Programming

991
views
gate2002
programminginc
programming
easy
3
answers
30
GATE20153_54
Consider the following C program #include<stdio.h> int f1(void); int f2(void); int f3(void); int x=10; int main() { int x=1; x += f1() + f2 () + f3() + f2(); printf("%d", x); return 0; } int f1() { int x = 25; x++; return x;} int f2() { static int x = 50; x++; return x;} int f3() { x *= 10; return x;} The output of the program is ______.
commented
Aug 31
in
Programming

1.7k
views
gate20153
programming
programminginc
normal
numericalanswers
3
answers
31
GATE19903viii
Choose the correct alternatives (More than one may be correct). Let $R_{1}$ and $R_{2}$ be regular sets defined over the alphabet $\Sigma$ Then: $R_{1} \cap R_{2}$ is not regular. $R_{1} \cup R_{2}$ is regular. $\Sigma^{*}R_{1}$ is regular. $R_{1}^{*}$ is not regular.
answered
Aug 31
in
Theory of Computation

365
views
gate1990
normal
theoryofcomputation
regularlanguages
11
answers
32
GATE2017122
Consider the language $L$ given by the regular expression $(a+b)^{*} b (a+b)$ over the alphabet {a,b}. The smallest number of states needed in a deterministic finitestate automaton (DFA) accepting $L$ is ___________ .
commented
Aug 31
in
Theory of Computation

2.4k
views
gate20171
theoryofcomputation
finiteautomata
numericalanswers
8
answers
33
GATE2017137
Consider the contextfree grammars over the alphabet $\left \{ a, b, c \right \}$ given below. $S$ and $T$ are nonterminals. $G_{1}:S\rightarrow aSbT, T\rightarrow cT\in$ $G_{2}:S\rightarrow bSaT, T\rightarrow cT\in$ The language $L\ ... )$ is (A) Finite. (B) Not finite but regular. (C) ContextFree but not regular. (D) Recursive but not contextfree.
answered
Aug 31
in
Theory of Computation

1.2k
views
gate20171
theoryofcomputation
contextfreelanguage
identifyclasslanguage
normal
6
answers
34
GATE2017239
Let $\delta$ denote the transition function and $\widehat{\delta}$ denote the extended transition function of the $\epsilon$NFA whose transition table is given below: $\delta$ $\epsilon$ $a$ $b$ $\rightarrow \: q_0$ $\{q_2\}$ $\{q_1\}$ $\{q_0\}$ $q_1$ $\{q_2\}$ $\ ... }(q_2, aba)$ is $\emptyset$ $\{q_0, q_1, q_3\}$ $\{q_0, q_1, q_2\}$ $\{q_0, q_2, q_3 \}$
commented
Aug 31
in
Theory of Computation

1.6k
views
gate20172
theoryofcomputation
finiteautomata
2
answers
35
GATE200868
Let R and S be two relations with the following schema $R(\underline{P}, \underline{Q}, R1, R2, R3)$ $S(\underline{P}, \underline{Q}, S1, S2)$ where $\left\{P, Q\right\}$ is the key for both schemas. Which of the following queries are equivalent? $\ ... Pi_{P,Q} \left(S\right)\right)\right)$ Only I and II Only I and III Only I, II and III Only I, III and IV
commented
Aug 30
in
Databases

1.7k
views
gate2008
databases
relationalalgebra
normal
4
answers
36
GATE200414
Consider the following relation schema pertaining to a students database: Students(rollno, name, address) Enroll(rollno, courseno, coursename) where the primary keys are shown underlined. The number of tuples in the student and Enroll tables are 120 and 8 respectively. ... in (Student * Enroll), where *' denotes natural join? 8, 8 120, 8 960, 8 960, 120
commented
Aug 30
in
Databases

2.2k
views
gate2004
databases
easy
joins
naturaljoin
3
answers
37
GATE200955
Consider the following relational schema: $\text{Suppliers}(\underline{\text{sid:integer}},\text{ sname:string, city:string, street:string})$ $\text{Parts}(\underline{\text{pid:integer}}, \text{ pname:string, color:string})$ $\text{ ... all suppliers who have supplied only nonblue part. Find the names of all suppliers who have not supplied only blue parts.
answered
Aug 30
in
Databases

2.8k
views
gate2009
databases
sql
subqueries
normal
4
answers
38
GATE200668
Consider the relation enrolled (student, course) in which (student, course) is the primary key, and the relation paid (student, amount) where student is the primary key. Assume no null values and no foreign keys or ... which Query3 returns strictly fewer rows than Query2 There exist databases for which Query4 will encounter an integrity violation at runtime
answer edited
Aug 30
in
Databases

1.9k
views
gate2006
databases
sql
normal
2
answers
39
GATE2011_32
Consider a database table T containing two columns $\text{X}$ and $\text{Y}$ each of type $\text{integer}$. After the creation of the table, one record $\text{(X=1, Y=1)}$ is inserted in the table. Let $\text{MX}$ and $\text{MY}$ denote the ... query after the steps mentioned above are carried out? SELECT Y FROM T WHERE X=7; (A) 127 (B) 255 (C) 129 (D) 257
answered
Aug 30
in
Databases

891
views
gate2011
databases
sql
normal
3
answers
40
GATE2014321
What is the optimized version of the relation algebra expression $\pi_{A1}(\pi_{A2}(\sigma_{F1}(\sigma_{F2}(r))))$, where $A1, A2$ are sets of attributes in $r$ with $A1 \subset A2$ and $F1,F2$ are Boolean expressions based on the attributes in $r$? $\pi_{A1}(\sigma_{ ... F2)}(r))$ $\pi_{A2}(\sigma_{(F1 \wedge F2)}(r))$ $\pi_{A2}(\sigma_{(F1 \vee F2)}(r))$
answered
Aug 30
in
Databases

649
views
gate20143
databases
relationalalgebra
easy
28,834
questions
36,686
answers
90,617
comments
34,640
users