Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Filter
Profile
Wall
Recent activity
All questions
All answers
Exams Taken
All Blogs
Answers by nikunj
5
votes
1
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
In dining philosophers Algorithm the minimum number of forks or chopsticks to avoid deadlock is (assume there are 5 philosophers)a. 5b. 6c. 10d. None of these
4.5k
views
answered
Sep 13, 2017
Operating System
operating-system
+
–
0
votes
2
Finite Automata to Regular Expression.Can this be solved further?
Convert the given Finite Automata to Regular Expression.
Convert the given Finite Automata to Regular Expression.
3.2k
views
answered
Sep 13, 2017
Theory of Computation
finite-automata
regular-expression
theory-of-computation
+
–
4
votes
3
GATE CSE 2009 | Question: 33
The enter_CS() and leave_CS() functions to implement critical section of a process are realized using test-and-set instruction as follows: void enter_CS(X) { while(test-and-set(X)); } void leave_CS(X) { X = 0; } In the above solution, $X$ is a memory location ... at the same time Which of the above statements are TRUE? (I) only (I) and (II) (II) and (III) (IV) only
The enter_CS() and leave_CS() functions to implement critical section of a process are realized using test-and-set instruction as follows:void enter_CS(X) { while(test-an...
25.1k
views
answered
Sep 10, 2017
Operating System
gatecse-2009
operating-system
process-synchronization
normal
+
–
1
votes
4
GATE CSE 2014 Set 2 | Question: 35
Let $\langle M \rangle$ be the encoding of a Turing machine as a string over $\Sigma=\left\{0,1\right\}$ ... $L$ is: decidable and recursively enumerable undecidable but recursively enumerable undecidable and not recursively enumerable decidable but not recursively enumerable
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 machi...
27.8k
views
answered
Sep 7, 2017
Theory of Computation
gatecse-2014-set2
theory-of-computation
turing-machine
normal
+
–
1
votes
5
GATE CSE 1987 | Question: 2h
State whether the following statements are TRUE or FALSE: Regularity is preserved under the operation of string reversal.
State whether the following statements are TRUE or FALSE:Regularity is preserved under the operation of string reversal.
3.7k
views
answered
Sep 7, 2017
Theory of Computation
gate1987
theory-of-computation
regular-language
true-false
+
–
0
votes
6
Regular or CFL
L={w| length of w is odd and its middle symbol is 0, wε{0,1}* } Reg or CFL?
L={w| length of w is odd and its middle symbol is 0, wε{0,1}* }Reg or CFL?
1.2k
views
answered
Sep 5, 2017
Theory of Computation
theory-of-computation
+
–
1
votes
7
CFL or not
L={ wε(a+b)* | #a - #b <=10 } CFL or Reg ?
L={ wε(a+b)* | #a - #b <=10 }CFL or Reg ?
502
views
answered
Sep 5, 2017
Theory of Computation
theory-of-computation
+
–
0
votes
8
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???
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???
794
views
answered
Sep 1, 2017
Theory of Computation
pushdown-automata
+
–
1
votes
9
GATE CSE 1990 | Question: 3-viii
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.
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 regu...
9.1k
views
answered
Aug 31, 2017
Theory of Computation
gate1990
normal
theory-of-computation
regular-language
multiple-selects
+
–
6
votes
10
GATE CSE 2017 Set 1 | Question: 37
Consider the context-free grammars over the alphabet $\left \{ a, b, c \right \}$ given below. $S$ and $T$ are non-terminals. $G_{1}:S\rightarrow aSb \mid T, T \rightarrow cT \mid \epsilon$ ... is Finite Not finite but regular Context-Free but not regular Recursive but not context-free
Consider the context-free grammars over the alphabet $\left \{ a, b, c \right \}$ given below. $S$ and $T$ are non-terminals.$G_{1}:S\rightarrow aSb \mid T, T \rightarrow...
12.3k
views
answered
Aug 31, 2017
Theory of Computation
gatecse-2017-set1
theory-of-computation
context-free-language
identify-class-language
normal
+
–
0
votes
11
GATE CSE 2009 | Question: 55
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})$ ... of all suppliers who have supplied only non-blue part. Find the names of all suppliers who have not supplied only blue parts.
Consider the following relational schema:$\text{Suppliers}(\underline{\text{sid:integer}},\text{ sname:string, city:string, street:string})$ $\text{Parts}(\underline{\tex...
38.6k
views
answered
Aug 30, 2017
Databases
gatecse-2009
databases
sql
normal
+
–
2
votes
12
GATE CSE 2006 | Question: 68
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 integrity constraints. ... strictly fewer rows than Query$2$ There exist databases for which Query$4$ will encounter an integrity violation at runtime
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. ...
20.4k
views
answered
Aug 30, 2017
Databases
gatecse-2006
databases
sql
normal
+
–
20
votes
13
GATE CSE 2011 | Question: 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 ... of the following SQL query after the steps mentioned above are carried out? SELECT Y FROM T WHERE X=7; $127$ $255$ $129$ $257$
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)}...
12.6k
views
answered
Aug 30, 2017
Databases
gatecse-2011
databases
sql
normal
+
–
5
votes
14
GATE CSE 2014 Set 3 | Question: 21
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_{A2}(\sigma_{(F1 \wedge F2)}(r))$ $\pi_{A2}(\sigma_{(F1 \vee F2)}(r))$
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...
10.8k
views
answered
Aug 30, 2017
Databases
gatecse-2014-set3
databases
relational-algebra
easy
+
–
27
votes
15
GATE IT 2007 | Question: 65
Consider a selection of the form $\sigma_{A\leq 100} (r)$, where $r$ is a relation with $1000$ tuples. Assume that the attribute values for $A$ among the tuples are uniformly distributed in the interval $[0, 500].$ Which one of the following options is the best estimate of the number of tuples returned by the given selection query ? $50$ $100$ $150$ $200$
Consider a selection of the form $\sigma_{A\leq 100} (r)$, where $r$ is a relation with $1000$ tuples. Assume that the attribute values for $A$ among the tuples are unifo...
12.8k
views
answered
Aug 29, 2017
Databases
gateit-2007
databases
relational-calculus
probability
normal
+
–
4
votes
16
GATE IT 2006 | Question: 61
In a database file structure, the search key field is $9$ $bytes$ long, the block size is $512$ $bytes$, a record pointer is $7$ $bytes$ and a block pointer is $6$ $bytes$. The largest possible order of a non-leaf node in a$ B+$ tree implementing this file structure is $23$ $24$ $34$ $44$
In a database file structure, the search key field is $9$ $bytes$ long, the block size is $512$ $bytes$, a record pointer is $7$ $bytes$ and a block pointer is $6$ $bytes...
6.9k
views
answered
Aug 29, 2017
Databases
gateit-2006
databases
b-tree
normal
+
–
3
votes
17
GATE IT 2004 | Question: 78
Consider two tables in a relational database with columns and rows as follows: ... 1 Both i and ii will fail i will fail but ii will succeed i will succeed but ii will fail Both i and ii will succeed
Consider two tables in a relational database with columns and rows as follows:$$\overset{\text{Table: Student}}{\begin{array}{|c|c|c|} \hline \textbf {Roll_no} & \textbf{...
11.0k
views
answered
Aug 29, 2017
Databases
gateit-2004
databases
sql
normal
+
–
1
votes
18
GATE IT 2007 | Question: 28
Consider a hash function that distributes keys uniformly. The hash table size is $20$. After hashing of how many keys will the probability that any new key hashed collides with an existing one exceed $0.5$. $5$ $6$ $7$ $10$
Consider a hash function that distributes keys uniformly. The hash table size is $20$. After hashing of how many keys will the probability that any new key hashed collide...
29.4k
views
answered
Aug 28, 2017
DS
gateit-2007
data-structures
hashing
probability
normal
+
–
1
votes
19
GATE IT 2006 | Question: 71
An array $X$ of $n$ distinct integers is interpreted as a complete binary tree. The index of the first element of the array is $0$. The index of the parent of element $X[i], i \neq 0$, is? $\left \lfloor \dfrac i 2 \right \rfloor$ $\left \lceil \dfrac{i-1}{2} \right \rceil$ $\left \lceil \dfrac i 2 \right \rceil$ $\left \lceil \dfrac i 2 \right \rceil - 1$
An array $X$ of $n$ distinct integers is interpreted as a complete binary tree. The index of the first element of the array is $0$. The index of the parent of element $X[...
13.7k
views
answered
Aug 28, 2017
DS
gateit-2006
data-structures
binary-tree
normal
+
–
1
votes
20
GATE CSE 2009 | Question: 56
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{2NF}$ but not in $\text{3NF}$ The schema is not in $\text{2NF}$
Consider the following relational schema:$\text{Suppliers}(\underline{\text{sid:integer}},\text{ sname:string, city:string, street:string})$ $\text{Parts}(\underline{\tex...
28.3k
views
answered
Aug 28, 2017
Databases
gatecse-2009
databases
sql
database-normalization
normal
+
–
1
votes
21
GATE CSE 2015 Set 3 | Question: 25
Consider a binary tree T that has $200$ leaf nodes. Then the number of nodes in T that have exactly two children are ______.
Consider a binary tree T that has $200$ leaf nodes. Then the number of nodes in T that have exactly two children are ______.
24.4k
views
answered
Aug 28, 2017
DS
gatecse-2015-set3
data-structures
binary-tree
normal
numerical-answers
+
–
3
votes
22
GATE CSE 1988 | Question: 2xvi
Write the adjacency matrix representation of the graph given in below figure.
Write the adjacency matrix representation of the graph given in below figure.
4.0k
views
answered
Dec 19, 2016
Graph Theory
gate1988
descriptive
graph-theory
graph-connectivity
+
–
3
votes
23
Ace Test Series: Databases - Er Diagram
433
views
answered
Dec 19, 2016
Databases
ace-test-series
databases
er-diagram
+
–
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register