Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Recent questions tagged gatecse-2008
3
votes
3
answers
1
GATE 2008 | Question 21
I have been trying to solve the question GATE CSE 2008 Question. Are the following two representations logically equivalent ? $\beta \rightarrow (\exists x, \alpha (x))$ $\exists x, \beta \rightarrow \alpha (x)$
I have been trying to solve the question GATE CSE 2008 Question.Are the following two representations logically equivalent ?$\beta \rightarrow (\exists x, \alpha (x))$$\e...
ParthPratim
1.0k
views
ParthPratim
asked
Nov 3, 2022
Mathematical Logic
gatecse-2008
mathematical-logic
first-order-logic
normal
+
–
30
votes
2
answers
2
GATE CSE 2008 | Question: 83
Consider the following $\text{ER}$ diagram The minimum number of tables needed to represent $M$, $N$, $P$, $R1$, $R2$ is Which of the following is a correct attribute set for one of the tables for the minimum number of tables needed to represent $M$, $N$, $P$, $R1$, $R2$? ${M1, M2, M3, P1}$ ${M1, P1, N1, N2}$ ${M1, P1, N1}$ ${M1, P1}$
Consider the following $\text{ER}$ diagramThe minimum number of tables needed to represent $M$, $N$, $P$, $R1$, $R2$ is Which of the following is a correct attribute set ...
Arjun
10.8k
views
Arjun
asked
Nov 27, 2016
Databases
gatecse-2008
databases
er-diagram
normal
+
–
24
votes
3
answers
3
GATE CSE 2008 | Question: 85
Consider the following C program that attempts to locate an element $x$ in an array $Y[ \ ]$ using binary search. The program is erroneous. f (int Y[10] , int x) { int i, j, k; i= 0; j = 9; do { k = (i + j) / 2; if( Y[k] < x) i = k;else j = k; } while (Y[k] ... if $(Y[k] < x) i = k$; else $j = k$; Change line 7 to: } while $((Y[k] == x) \&\& (i < j))$ ;
Consider the following C program that attempts to locate an element $x$ in an array $Y[ \ ]$ using binary search. The program is erroneous. f (int Y[10] , int x) { int i,...
go_editor
7.0k
views
go_editor
asked
Apr 23, 2016
Algorithms
gatecse-2008
algorithms
searching
normal
+
–
32
votes
6
answers
4
GATE CSE 2008 | Question: 73
Consider a machine with a $2$-way set associative data cache of size $64$ Kbytes and block size $16$ bytes. The cache is managed using $32$ bit virtual addresses and the page size is $4$ Kbytes. A program to be run on this machine begins as follows: double ARR[ ... to array $\text{ARR}$. The cache hit ratio for this initialization loop is: $0\%$ $25\%$ $50\%$ $75\%$
Consider a machine with a $2$-way set associative data cache of size $64$ Kbytes and block size $16$ bytes. The cache is managed using $32$ bit virtual addresses and the ...
go_editor
8.5k
views
go_editor
asked
Apr 23, 2016
CO and Architecture
gatecse-2008
co-and-architecture
cache-memory
normal
+
–
61
votes
6
answers
5
GATE CSE 2008 | Question: 72
Consider a machine with a $2$-way set associative data cache of size $64$ Kbytes and block size $16$ bytes. The cache is managed using $32$ bit virtual addresses and the page size is $4$ Kbytes. A program to be run on this machine begins as follows: double ARR[1024][1024]; int i, j; ... $\text{ARR[0][4]}$ $\text{ARR[4][0]}$ $\text{ARR[0][5]}$ $\text{ARR[5][0]}$
Consider a machine with a $2$-way set associative data cache of size $64$ Kbytes and block size $16$ bytes. The cache is managed using $32$ bit virtual addresses and the ...
go_editor
15.7k
views
go_editor
asked
Apr 23, 2016
CO and Architecture
gatecse-2008
co-and-architecture
cache-memory
normal
+
–
33
votes
5
answers
6
GATE CSE 2008 | Question: 75
Consider the following C functions: int f1 (int n) { if(n == 0 || n == 1) return n; else return (2 * f1(n-1) + 3 * f1(n-2)); } int f2(int n) { int i; int X[N], Y[N], Z[N]; X[0] = Y[0] = Z[0] = 0; X[1] = 1; Y[1] = 2; Z[1] = 3; for(i ... ] = 3 * X[i]; } return X[n]; } $f1(8)$ and $f2(8)$ return the values $1661$ and $1640$ $59$ and $59$ $1640$ and $1640$ $1640$ and $1661$
Consider the following C functions:int f1 (int n) { if(n == 0 || n == 1) return n; else return (2 * f1(n-1) + 3 * f1(n-2)); } int f2(int n) { int i; int X[N], Y[N], Z[N];...
go_editor
12.7k
views
go_editor
asked
Apr 23, 2016
Algorithms
gatecse-2008
normal
algorithms
time-complexity
+
–
49
votes
7
answers
7
GATE CSE 2008 | Question: 77
Delayed branching can help in the handling of control hazards The following code is to run on a pipelined processor with one branch delay slot: I1: ADD $R2 \leftarrow R7 + R8$ I2: Sub $R4 \leftarrow R5 – R6$ ... Which of the instructions I1, I2, I3 or I4 can legitimately occupy the delay slot without any program modification? I1 I2 I3 I4
Delayed branching can help in the handling of control hazardsThe following code is to run on a pipelined processor with one branch delay slot:I1: ADD $R2 \leftarrow R7 + ...
go_editor
15.3k
views
go_editor
asked
Apr 23, 2016
CO and Architecture
gatecse-2008
co-and-architecture
pipelining
normal
+
–
24
votes
6
answers
8
GATE CSE 2008 | Question: 79
Let $x_n$ denote the number of binary strings of length $n$ that contain no consecutive $0$s. The value of $x_5$ is $5$ $7$ $8$ $16$
Let $x_n$ denote the number of binary strings of length $n$ that contain no consecutive $0$s.The value of $x_5$ is $5$$7$$8$$16$
go_editor
5.3k
views
go_editor
asked
Apr 23, 2016
Algorithms
gatecse-2008
algorithms
recurrence-relation
normal
+
–
33
votes
2
answers
9
GATE CSE 2008 | Question: 81
The subset-sum problem is defined as follows. Given a set of $n$ positive integers, $S = \{ a_1, a_2, a_3, \dots , a_n \}$, and positive integer $W$, is there a subset of $S$ whose elements sum to $W$? A dynamic program for solving this problem uses a $\text{2-dimensional}$ ... that there is a subset whose elements sum to $W$? $X[1, W]$ $X[n, 0]$ $X[n, W]$ $X[n-1, n]$
The subset-sum problem is defined as follows. Given a set of $n$ positive integers, $S = \{ a_1, a_2, a_3, \dots , a_n \}$, and positive integer $W$, is there a subset of...
go_editor
10.2k
views
go_editor
asked
Apr 23, 2016
Algorithms
gatecse-2008
algorithms
normal
dynamic-programming
+
–
76
votes
6
answers
10
GATE CSE 2008 | Question: 42
$G$ is a graph on $n$ vertices and $2n-2$ edges. The edges of $G$ can be partitioned into two edge-disjoint spanning trees. Which of the following is NOT true for $G$? For every subset of $k$ vertices, the induced subgraph has at ... least $2$ edge-disjoint paths between every pair of vertices. There are at least $2$ vertex-disjoint paths between every pair of vertices.
$G$ is a graph on $n$ vertices and $2n-2$ edges. The edges of $G$ can be partitioned into two edge-disjoint spanning trees. Which of the following is NOT true for $G$?For...
Akshay Jindal
23.6k
views
Akshay Jindal
asked
Sep 27, 2014
Graph Theory
gatecse-2008
graph-connectivity
normal
+
–
44
votes
4
answers
11
GATE CSE 2008 | Question: 80
The subset-sum problem is defined as follows. Given a set of $n$ positive integers, $S = \{ a_1, a_2, a_3, \dots , a_n \}$, and positive integer $W$, is there a subset of $S$ whose elements sum to $W$? A dynamic program for solving this problem uses a $\text{2-dimensional}$ Boolean array, ... $X[i, j] = X[i-1, j] \wedge X[i-1, j-a_i]$
The subset-sum problem is defined as follows. Given a set of $n$ positive integers, $S = \{ a_1, a_2, a_3, \dots , a_n \}$, and positive integer $W$, is there a subset of...
Kathleen
11.7k
views
Kathleen
asked
Sep 12, 2014
Algorithms
gatecse-2008
algorithms
normal
dynamic-programming
+
–
42
votes
10
answers
12
GATE CSE 2008 | Question: 78
Let $x_n$ denote the number of binary strings of length $n$ that contain no consecutive $0$s. Which of the following recurrences does $x_n$ satisfy? $x_n = 2x_{n-1}$ $x_n = x_{\lfloor n/2 \rfloor} + 1$ $x_n = x_{\lfloor n/2 \rfloor} + n$ $x_n = x_{n-1} + x_{n-2}$
Let $x_n$ denote the number of binary strings of length $n$ that contain no consecutive $0$s.Which of the following recurrences does $x_n$ satisfy?$x_n = 2x_{n-1}$$x_n = ...
Kathleen
8.5k
views
Kathleen
asked
Sep 12, 2014
Algorithms
gatecse-2008
algorithms
recurrence-relation
normal
+
–
64
votes
3
answers
13
GATE CSE 2008 | Question: 76
Delayed branching can help in the handling of control hazards For all delayed conditional branch instructions, irrespective of whether the condition evaluates to true or false, The instruction following the conditional branch instruction in memory is ... The first instruction in the taken path is executed The branch takes longer to execute than any other instruction
Delayed branching can help in the handling of control hazardsFor all delayed conditional branch instructions, irrespective of whether the condition evaluates to true or f...
Kathleen
17.9k
views
Kathleen
asked
Sep 12, 2014
CO and Architecture
gatecse-2008
co-and-architecture
pipelining
normal
+
–
40
votes
6
answers
14
GATE CSE 2008 | Question: 74
Consider the following C functions: int f1 (int n) { if(n == 0 || n == 1) return n; else return (2 * f1(n-1) + 3 * f1(n-2)); } int f2(int n) { int i; int X[N], Y[N], Z[N]; X[0] = Y[0] = Z[0] = 0; X[1] = 1; Y[1] = 2; Z[1] = 3; for(i = 2 ... $f2(n)$ are $\Theta(n)$ and $\Theta(n)$ $\Theta(2^n)$ and $\Theta(n)$ $\Theta(n)$ and $\Theta(2^n)$ $\Theta(2^n)$ and $\Theta(2^n)$
Consider the following C functions:int f1 (int n) { if(n == 0 || n == 1) return n; else return (2 * f1(n-1) + 3 * f1(n-2)); } int f2(int n) { int i; int X[N], Y[N], Z[N];...
Kathleen
18.9k
views
Kathleen
asked
Sep 12, 2014
Algorithms
gatecse-2008
algorithms
time-complexity
normal
+
–
61
votes
4
answers
15
GATE CSE 2008 | Question: 71
Consider a machine with a $2$-way set associative data cache of size $64\text{Kbytes}$ and block size $16\text{bytes}$. The cache is managed using $32\;\text{bit}$ virtual addresses and the page size is $4\text{Kbytes}$. A program to be run on this ... total size of the tags in the cache directory is: $32\text{Kbits}$ $34\text{Kbits}$ $64\text{Kbits}$ $68\text{Kbits}$
Consider a machine with a $2$-way set associative data cache of size $64\text{Kbytes}$ and block size $16\text{bytes}$. The cache is managed using $32\;\text{bit}$ virtua...
Kathleen
18.7k
views
Kathleen
asked
Sep 12, 2014
CO and Architecture
gatecse-2008
co-and-architecture
cache-memory
normal
+
–
60
votes
5
answers
16
GATE CSE 2008 | Question: 69
Consider the following relational schemes for a library database: Book (Title, Author, Catalog_no, Publisher, Year, Price) Collection(Title, Author, Catalog_no) with the following functional dependencies: $\text{Title Author }\rightarrow\text{ Catalog_no}$ ... $\text{2NF}$ and Collection in $\text{3NF}$ Both Book and Collection are in $\text{2NF}$ only
Consider the following relational schemes for a library database:Book (Title, Author, Catalog_no, Publisher, Year, Price) Collection(Title, Author, Catalog_no)with the fo...
Kathleen
28.1k
views
Kathleen
asked
Sep 12, 2014
Databases
gatecse-2008
databases
database-normalization
normal
+
–
66
votes
4
answers
17
GATE CSE 2008 | Question: 68
Let R and S be two relations with the following schema $R(\underline{P,Q}, R1, R2, R3)$ $S(\underline{P,Q}, S1, S2)$ where $\left\{P, Q\right\}$ is the key for both schemas. Which of the following queries are equivalent? $\Pi_P \left(R \bowtie S\right)$ ... Only I and II Only I and III Only I, II and III Only I, III and IV
Let R and S be two relations with the following schema$R(\underline{P,Q}, R1, R2, R3)$$S(\underline{P,Q}, S1, S2)$where $\left\{P, Q\right\}$ is the key for both schemas....
Kathleen
18.0k
views
Kathleen
asked
Sep 12, 2014
Databases
gatecse-2008
databases
relational-algebra
normal
+
–
277
votes
14
answers
18
GATE CSE 2008 | Question: 67
A processor uses $36$ bit physical address and $32$ bit virtual addresses, with a page frame size of $4$ Kbytes. Each page table entry is of size $4$ bytes. A three level page table is used for virtual to physical address translation, where the virtual address is used as ... tables are respectively $\text{20,20,20}$ $\text{24,24,24}$ $\text{24,24,20}$ $\text{25,25,24}$
A processor uses $36$ bit physical address and $32$ bit virtual addresses, with a page frame size of $4$ Kbytes. Each page table entry is of size $4$ bytes. A three level...
Kathleen
76.4k
views
Kathleen
asked
Sep 12, 2014
Operating System
gatecse-2008
operating-system
virtual-memory
normal
+
–
29
votes
3
answers
19
GATE CSE 2008 | Question: 66
A process executes the following code for(i=0; i<n; i++) fork(); The total number of child processes created is $n$ $2^n-1$ $2^n$ $2^{n+1} - 1$
A process executes the following codefor(i=0; i<n; i++) fork();The total number of child processes created is$n$$2^n-1$$2^n$$2^{n+1} - 1$
Kathleen
17.1k
views
Kathleen
asked
Sep 12, 2014
Operating System
gatecse-2008
operating-system
fork-system-call
normal
+
–
54
votes
4
answers
20
GATE CSE 2008 | Question: 65
Which of the following is NOT true of deadlock prevention and deadlock avoidance schemes? In deadlock prevention, the request for resources is always granted if the resulting state is safe In deadlock avoidance, the request ... safe Deadlock avoidance is less restrictive than deadlock prevention Deadlock avoidance requires knowledge of resource requirements apriori..
Which of the following is NOT true of deadlock prevention and deadlock avoidance schemes?In deadlock prevention, the request for resources is always granted if the result...
Kathleen
24.0k
views
Kathleen
asked
Sep 12, 2014
Operating System
gatecse-2008
operating-system
easy
resource-allocation
+
–
41
votes
6
answers
21
GATE CSE 2008 | Question: 64, ISRO2009-13
Which of the following statements about synchronous and asynchronous I/O is NOT true? An ISR is invoked on completion of I/O in synchronous I/O but not in asynchronous I/O In both synchronous and asynchronous I/O, an ISR (Interrupt Service ... process waiting for the completion of I/O is woken up by the ISR that is invoked after the completion of I/O
Which of the following statements about synchronous and asynchronous I/O is NOT true?An ISR is invoked on completion of I/O in synchronous I/O but not in asynchronous I/O...
Kathleen
17.7k
views
Kathleen
asked
Sep 12, 2014
CO and Architecture
gatecse-2008
operating-system
io-handling
normal
isro2009
+
–
68
votes
8
answers
22
GATE CSE 2008 | Question: 63
The $P$ and $V$ operations on counting semaphores, where s is a counting semaphore, are defined as follows: $P(s):$ $s=s-1;$ If $s < 0$ then wait; $V(s):$ $s=s+1;$ If $s \leq0$ then wake up process waiting on s; Assume that $P_b$ and $V_b$ the wait ... $x_b$ and $y_b$ are respectively $0$ and $0$ $0$ and $1$ $1$ and $0$ $1$ and $1$
The $P$ and $V$ operations on counting semaphores, where s is a counting semaphore, are defined as follows:$P(s):$$s=s-1;$If $s < 0$ then wait;$V(s):$$s=s+1;$If $s \leq0$...
Kathleen
23.1k
views
Kathleen
asked
Sep 12, 2014
Operating System
gatecse-2008
operating-system
normal
semaphore
+
–
42
votes
4
answers
23
GATE CSE 2008 | Question: 62
The following C function takes a single-linked list of integers as a parameter and rearranges the elements of the list. The function is called with the list containing the integers $1, 2, 3, 4, 5, 6, 7$ in the given order. What will be the contents of the list after function completes execution? struct ... $1, 3, 2, 5, 4, 7, 6$ $2, 3, 4, 5, 6, 7, 1$
The following C function takes a single-linked list of integers as a parameter and rearranges the elements of the list. The function is called with the list containing th...
Kathleen
19.2k
views
Kathleen
asked
Sep 12, 2014
DS
gatecse-2008
data-structures
linked-list
normal
+
–
28
votes
5
answers
24
GATE CSE 2008 | Question: 61
Choose the correct option to fill $?1$ and $?2$ so that the program below prints an input string in reverse order. Assume that the input string is terminated by a new line character. void reverse(void) { int c; if(?1) reverse(); ?2 } main() { printf("Enter text"); ... $?2$ is $putchar(c);$ $?1$ is $((c = getchar() ) != '\setminus n')$ $?2$ is $putchar(c);$
Choose the correct option to fill $?1$ and $?2$ so that the program below prints an input string in reverse order. Assume that the input string is terminated by a new lin...
Kathleen
8.0k
views
Kathleen
asked
Sep 12, 2014
Programming in C
gatecse-2008
programming
normal
programming-in-c
+
–
44
votes
4
answers
25
GATE CSE 2008 | Question: 60
What is printed by the following C program? int f(int x, int *py, int **ppz) { int y, z; **ppz += 1; z = **ppz; // corrected z = *ppz; to z = **ppz; *py += 2; y = *py; x += 3; return x+y+z; } void main() { int c, *b, **a; c = 4; b = &c; a = &b; printf("%d", f(c, b, a)); } $18$ $19$ $21$ $22$
What is printed by the following C program?int f(int x, int *py, int ppz) { int y, z; ppz += 1; z = ppz; // corrected z = *ppz; to z = ppz; *py += 2; y = *py; x += 3;...
Kathleen
17.9k
views
Kathleen
asked
Sep 12, 2014
Programming in C
gatecse-2008
programming
programming-in-c
normal
parameter-passing
+
–
46
votes
3
answers
26
GATE CSE 2008 | Question: 59
A client process P needs to make a TCP connection to a server process S. Consider the following situation: the server process S executes a $\text{socket()}$, a $\text{bind()}$ and a $\text{listen()}$ system call in that order, following which ... $\text{connect()}$ system call returns an error $\text{connect()}$ system call results in a core dump
A client process P needs to make a TCP connection to a server process S. Consider the following situation: the server process S executes a $\text{socket()}$, a $\text{bin...
Kathleen
16.7k
views
Kathleen
asked
Sep 12, 2014
Computer Networks
gatecse-2008
computer-networks
sockets
normal
+
–
34
votes
9
answers
27
GATE CSE 2008 | Question: 58
A computer on a $10\text{Mbps}$ network is regulated by a token bucket. The token bucket is filled at a rate of $2\text{Mbps}$. It is initially filled to capacity with $16\text{Megabits}$. What is the maximum duration for which the computer can transmit at the full $10\text{Mbps}$? $1.6$ seconds $2$ seconds $5$ seconds $8$ seconds
A computer on a $10\text{Mbps}$ network is regulated by a token bucket. The token bucket is filled at a rate of $2\text{Mbps}$. It is initially filled to capacity with $1...
Kathleen
25.0k
views
Kathleen
asked
Sep 12, 2014
Computer Networks
gatecse-2008
computer-networks
token-bucket
+
–
26
votes
2
answers
28
GATE CSE 2008 | Question: 57
If a class $B$ network on the Internet has a subnet mask of $255.255.248.0$, what is the maximum number of hosts per subnet? $1022$ $1023$ $2046$ $2047$
If a class $B$ network on the Internet has a subnet mask of $255.255.248.0$, what is the maximum number of hosts per subnet?$1022$$1023$$2046$$2047$
Kathleen
13.8k
views
Kathleen
asked
Sep 12, 2014
Computer Networks
gatecse-2008
computer-networks
subnetting
easy
+
–
26
votes
4
answers
29
GATE CSE 2008 | Question: 56
In the slow start phase of the TCP congestion algorithm, the size of the congestion window: does not increase increase linearly increases quadratically increases exponentially
In the slow start phase of the TCP congestion algorithm, the size of the congestion window:does not increaseincrease linearlyincreases quadraticallyincreases exponentiall...
Kathleen
10.1k
views
Kathleen
asked
Sep 12, 2014
Computer Networks
gatecse-2008
computer-networks
congestion-control
normal
+
–
37
votes
3
answers
30
GATE CSE 2008 | Question: 55
An LALR(1) parser for a grammar G can have shift-reduce (S-R) conflicts if and only if The SLR(1) parser for G has S-R conflicts The LR(1) parser for G has S-R conflicts The LR(0) parser for G has S-R conflicts The LALR(1) parser for G has reduce-reduce conflicts
An LALR(1) parser for a grammar G can have shift-reduce (S-R) conflicts if and only ifThe SLR(1) parser for G has S-R conflictsThe LR(1) parser for G has S-R conflictsThe...
Kathleen
15.8k
views
Kathleen
asked
Sep 12, 2014
Compiler Design
gatecse-2008
compiler-design
parsing
normal
+
–
Page:
1
2
3
next »
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register