GATE 2024 (Session 2)
65 questions
MCQ 32 · MSQ 18 · NAT 151-mark 30 · 2-mark 35
Questions 11–15 of 65
Consider a computer with a 4 MHz processor. Its DMA controller can transfer 8 bytes in 1 cycle from a device to main memory through cycle stealing at regular intervals. Which one of the following is the data transfer rate (in bits per second) of the DMA controller if 1% of the processor cycles are used for DMA?
Answer: (C)
DMA uses this many cycles in one second: .
One cycle moves 8 bytes, which is 64 bits.
Data transfer rate: bits/s, so the rate is 25,60,000 bps.
Answer: 25,60,000
One cycle moves 8 bytes, which is 64 bits.
Data transfer rate: bits/s, so the rate is 25,60,000 bps.
Answer: 25,60,000
Let and be the following propositions:
: Fail grade can be given.
: Student scores more than marks.
Consider the statement: "Fail grade cannot be given when student scores more than marks."
Which one of the following is the CORRECT representation of the above statement in propositional logic?
: Fail grade can be given.
: Student scores more than marks.
Consider the statement: "Fail grade cannot be given when student scores more than marks."
Which one of the following is the CORRECT representation of the above statement in propositional logic?
Answer: (A)
The statement "Fail grade cannot be given when student scores more than 50%" reads: if (marks 50%), then not (no fail grade).
Answer:
Answer:
Consider the following C program. Assume parameters to a function are evaluated from right to left.
#include <stdio.h>
int g(int p) { printf("%d", p); return p; }
int h(int q) { printf("%d", q); return q; }
void f(int x, int y) {
g(x);
h(y);
}
int main() {
f(g(10),h(20));
} Which one of the following options is the CORRECT output of the above C program?Answer: (A)
The arguments of f are evaluated from right to left:
- First, h(20) is called and it prints 20
- Next, g(10) is called and it prints 10
Now f(10, 20) runs:
- g(x) prints 10
- h(y) prints 20
Output: 20101020
Answer: 20101020
- First, h(20) is called and it prints 20
- Next, g(10) is called and it prints 10
Now f(10, 20) runs:
- g(x) prints 10
- h(y) prints 20
Output: 20101020
Answer: 20101020
The format of a single-precision floating-point number as per the IEEE 754 standard is:
Choose the largest floating-point number among the following options.
Choose the largest floating-point number among the following options.
Answer: (B)
In IEEE 754, an exponent of all 1s (255) is reserved for /NaN.
- (A): the exponent is 127
- (B): the exponent is , so this is the largest finite number
- (C): the exponent is 255 and the mantissa is non-zero NaN, which is not a number at all
- (D):
Answer: B
- (A): the exponent is 127
- (B): the exponent is , so this is the largest finite number
- (C): the exponent is 255 and the mantissa is non-zero NaN, which is not a number at all
- (D):
Answer: B
Let be the recurrence relation defined as follows:
Which one of the following statements is TRUE?
Which one of the following statements is TRUE?
Answer: (A)
Characteristic equation: .
General form of the solution:
Use the first starting value:
Use the second starting value:
Solving both gives , and so (check: , True).
Answer:
General form of the solution:
Use the first starting value:
Use the second starting value:
Solving both gives , and so (check: , True).
Answer: