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
Recent activity by nbnb
5
answers
1
GATE CSE 2004 | Question: 58
A circuit outputs a digit in the form of $4$ bits. $0$ is represented by $0000, 1$ by $0001, \ldots, 9$ by $1001$. A combinational circuit is to be designed which takes these $4$ bits as input and outputs $1$ if the digit $\geq$ $5$, and $0$ otherwise ... $\textsf{NOT}$ gates may be used, what is the minimum number of gates required? $2$ $3$ $4$ $5$
A circuit outputs a digit in the form of $4$ bits. $0$ is represented by $0000, 1$ by $0001, \ldots, 9$ by $1001$. A combinational circuit is to be designed which takes t...
11.9k
views
commented
Jan 27, 2018
Digital Logic
gatecse-2004
digital-logic
normal
min-no-gates
+
–
5
answers
2
GATE CSE 2016 Set 1 | Question: 44
Let $X$ be a recursive language and $Y$ be a recursively enumerable but not recursive language. Let $W$ and $Z$ be two languages such that $\overline{Y}$ reduces to $W$, and $Z$ reduces to $\overline{X}$ (reduction means the standard ... enumerable. $W$ is not recursively enumerable and $Z$ is recursive. $W$ is not recursively enumerable and $Z$ is not recursive.
Let $X$ be a recursive language and $Y$ be a recursively enumerable but not recursive language. Let $W$ and $Z$ be two languages such that $\overline{Y}$ reduces to $W$,...
12.4k
views
commented
Jan 25, 2018
Theory of Computation
gatecse-2016-set1
theory-of-computation
easy
recursive-and-recursively-enumerable-languages
reduction
+
–
5
answers
3
GATE CSE 2005 | Question: 59
Consider the grammar: $E \rightarrow E + n \mid E \times n \mid n$ For a sentence $n + n \times n$, the handles in the right-sentential form of the reduction are: $n, E + n$ and $E + n \times n$ $n, E + n$ and $E + E \times n$ $n, n + n$ and $n + n \times n$ $n, E + n$ and $E \times n$
Consider the grammar:$$E \rightarrow E + n \mid E \times n \mid n$$For a sentence $n + n \times n$, the handles in the right-sentential form of the reduction are:$n, E + ...
16.3k
views
commented
Jan 14, 2018
Compiler Design
gatecse-2005
compiler-design
grammar
normal
+
–
6
answers
4
GATE CSE 2016 Set 1 | Question: 31
The size of the data count register of a $\text{DMA}$ controller is $16\;\text{bits}$. The processor needs to transfer a file of $29,154$ kilobytes from disk to main memory. The memory is byte addressable. The minimum number of times ... needs to get the control of the system bus from the processor to transfer the file from the disk to main memory is _________.
The size of the data count register of a $\text{DMA}$ controller is $16\;\text{bits}$. The processor needs to transfer a file of $29,154$ kilobytes from disk to main memo...
18.6k
views
commented
Dec 26, 2017
CO and Architecture
gatecse-2016-set1
co-and-architecture
dma
normal
numerical-answers
+
–
11
answers
5
GATE IT 2007 | Question: 24
A depth-first search is performed on a directed acyclic graph. Let $d[u]$ denote the time at which vertex $u$ is visited for the first time and $f[u]$ the time at which the DFS call to the vertex $u$ terminates. Which of the following statements is always TRUE for all edges $(u, v)$ in the graph ? $d[u] < d[v]$ $d[u] < f[v]$ $f[u] < f[v]$ $f[u] > f[v]$
A depth-first search is performed on a directed acyclic graph. Let $d[u]$ denote the time at which vertex $u$ is visited for the first time and $f[u]$ the time at which t...
13.7k
views
commented
Dec 21, 2017
Algorithms
gateit-2007
algorithms
graph-algorithms
normal
graph-search
depth-first-search
+
–
4
answers
6
ISICAL MTech 2014 CS
How many asterisks $(*)$ in terms of $k$ will be printed by the following C function, when called as $\text{count}(m)$ where $m = 3^k \ ?$ Justify your answer. Assume that $4$ bytes are used to store an integer in C and $k$ is such that $3^k$ can be stored in $4$ bytes. void count(int n){ printf("*"); if(n>1){ count(n/3); count(n/3); count(n/3); } }
How many asterisks $(*)$ in terms of $k$ will be printed by the following C function, when called as $\text{count}(m)$ where $m = 3^k \ ?$ Justify your answer.Assume that...
1.6k
views
commented
Dec 19, 2017
Programming in C
programming-in-c
recursion
isi2014
+
–
2
answers
7
GATE IT 2004 | Question: 61
Consider the following C program: #include <stdio.h> typedef struct { char *a; char *b; } t; void f1 (t s); void f2 (t *p); main() { static t s = {"A", "B"}; printf ("%s %s\n", s.a, s.b); f1(s); printf ("%s %s\n", s.a, s.b); f2(&s); } void ... $A \ B$ $V \ W$ $A \ B$ $U \ V$ $U \ V$ $V \ W$ $A \ B$ $U \ V$ $V \ W$ $U \ V$
Consider the following C program:#include <stdio.h typedef struct { char *a; char *b; } t; void f1 (t s); void f2 (t *p); main() { static t s = {"A", "B"}; printf ("%s %s...
10.0k
views
commented
Dec 19, 2017
Programming in C
gateit-2004
programming
programming-in-c
normal
structure
+
–
5
answers
8
GATE CSE 2004 | Question: 32
Consider the following program fragment for reversing the digits in a given integer to obtain a new integer. Let $n = d_1\, d_2\, \ldots\, d_m$. int n, rev; rev = 0; while(n > 0) { rev = rev * 10 + n%10; n = n/10; } The loop invariant condition at the end ... $n=d_1\, d_2 \,\ldots\, d_m \qquad \mathbf{or} \qquad \text{rev} =d_m \,\ldots\, d_2\, d_1$
Consider the following program fragment for reversing the digits in a given integer to obtain a new integer.Let $n = d_1\, d_2\, \ldots\, d_m$.int n, rev; rev = 0; while(...
12.2k
views
commented
Dec 18, 2017
Programming in C
gatecse-2004
programming
loop-invariants
normal
+
–
4
answers
9
ISI2015-PCB-CS-5a
Construct two nonregular languages $L_1$ and $L_2$ such that $L_1 \cup L_2$ is regular. Prove that the languages $L_1$ and $L_2$ constructed above are nonregular and $L_1 \cup L_2$ is regular.
Construct two nonregular languages $L_1$ and $L_2$ such that $L_1 \cup L_2$ is regular.Prove that the languages $L_1$ and $L_2$ constructed above are nonregular and $L_1 ...
1.8k
views
commented
Dec 2, 2017
Theory of Computation
descriptive
isi2015-pcb-cs
theory-of-computation
regular-language
+
–
4
answers
10
TIFR CSE 2017 | Part B | Question: 8
For any natural number $n$, an ordering of all binary strings of length $n$ is a Gray code if it starts with $0^n$, and any successive strings in the ordering differ in exactly one bit (the first and last string must also differ by one ... two strings are separated by $k$ other strings in the ordering, then they must differ in exactly $k$ bits none of the above
For any natural number $n$, an ordering of all binary strings of length $n$ is a Gray code if it starts with $0^n$, and any successive strings in the ordering differ in e...
3.2k
views
commented
Nov 30, 2017
Digital Logic
tifr2017
digital-logic
boolean-algebra
+
–
2
answers
11
GATE CSE 1990 | Question: 3-vii
It is undecidable whether: An arbitrary Turing machine halts after $100$ steps. A Turing machine prints a specific letter. A Turing machine computes the products of two numbers None of the above.
It is undecidable whether:An arbitrary Turing machine halts after $100$ steps.A Turing machine prints a specific letter.A Turing machine computes the products of two numb...
12.6k
views
commented
Nov 27, 2017
Theory of Computation
gate1990
normal
theory-of-computation
decidability
multiple-selects
+
–
11
answers
12
GATE CSE 2017 Set 2 | Question: 16
Identify the language generated by the following grammar, where $S$ is the start variable. $ S \rightarrow XY$ $ X \rightarrow aX \mid a$ $ Y \rightarrow aYb \mid \epsilon$ $\{a^mb^n \mid m \geq n, n > 0 \}$ $ \{ a^mb^n \mid m \geq n, n \geq 0 \}$ $\{a^mb^n \mid m > n, n \geq 0 \}$ $\{a^mb^n \mid m > n, n > 0 \}$
Identify the language generated by the following grammar, where $S$ is the start variable.$ S \rightarrow XY$$ X \rightarrow aX \mid a$$ Y \rightarrow aYb \mid \epsilon$$...
18.4k
views
commented
Nov 27, 2017
Theory of Computation
gatecse-2017-set2
theory-of-computation
context-free-language
+
–
4
answers
13
GATE CSE 1999 | Question: 1.20
Booth's coding in $8$ bits for the decimal number $-57$ is: $0-100+1000$ $0-100+100-1$ $0-1+100-10+1$ $00-10+100-1$
Booth's coding in $8$ bits for the decimal number $-57$ is:$0-100+1000$$0-100+100-1$$0-1+100-10+1$$00-10+100-1$
13.3k
views
commented
Nov 22, 2017
Digital Logic
gate1999
digital-logic
number-representation
booths-algorithm
normal
+
–
6
answers
14
GATE CSE 1993 | Question: 11
In the three-level memory hierarchy shown in the following table, $p_i$ denotes the probability that an access request will refer to $M_i$ ... a page swap is $T_i$. Calculate the average time $t_A$ required for a processor to read one word from this memory system.
In the three-level memory hierarchy shown in the following table, $p_i$ denotes the probability that an access request will refer to $M_i$.$$\begin{array}{|c|c|c|c|} \hli...
11.0k
views
commented
Nov 11, 2017
CO and Architecture
gate1993
co-and-architecture
cache-memory
normal
descriptive
+
–
10
answers
15
GATE CSE 2007 | Question: 80
Consider a machine with a byte addressable main memory of $2^{16}$ bytes. Assume that a direct mapped data cache consisting of $32$ lines of $64$ bytes each is used in the system. A $50 \times 50$ two-dimensional array of bytes is stored in the main ... data cache do not change in between the two accesses. How many data misses will occur in total? $48$ $50$ $56$ $59$
Consider a machine with a byte addressable main memory of $2^{16}$ bytes. Assume that a direct mapped data cache consisting of $32$ lines of $64$ bytes each is used in th...
32.5k
views
commented
Nov 11, 2017
CO and Architecture
gatecse-2007
co-and-architecture
cache-memory
normal
+
–
10
answers
16
GATE CSE 2010 | Question: 39
Let $L=\{ w \in \:(0+1)^* \mid w\text{ has even number of }1s \}$. i.e., $L$ is the set of all the bit strings with even numbers of $1$s. Which one of the regular expressions below represents $L$? $(0^*10^*1)^*$ $0^*(10^*10^*)^*$ $0^*(10^*1)^*0^*$ $0^*1(10^*1)^*10^*$
Let $L=\{ w \in \:(0+1)^* \mid w\text{ has even number of }1s \}$. i.e., $L$ is the set of all the bit strings with even numbers of $1$s. Which one of the regular express...
22.3k
views
commented
Mar 8, 2017
Theory of Computation
gatecse-2010
theory-of-computation
regular-expression
normal
+
–
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register