• Courses
  • Tutorials
  • Jobs
  • Practice
  • Contests

GATE-CS-2016 (Set 1)

Question 61

An IP datagram of size 1000 bytes arrives at a router. The router has to forward this packet on a link whose MTU (maximum transmission unit) is 100 bytes. Assume that the size of the IP header is 20 bytes. The number of fragments that the IP datagram will be divided into for transmission is :   Note : This question was asked as Numerical Answer Type.
  • 10
  • 50
  • 12
  • 13

Question 62

For a host machine that uses the token bucket algorithm for congestion control, the token bucket has a capacity of 1 megabyte and the maximum output rate is 20 megabytes per second. Tokens arrive at a rate to sustain output at a rate of 10 megabytes per second. The token bucket is currently full and the machine needs to send 12 megabytes of data. The minimum time required to transmit the data is _________________ seconds.
  • 1.1
  • 0.1
  • 2.1
  • 2.0

Question 63

A sender uses the Stop-and-Wait ARQ protocol for reliable transmission of frames. Frames are of size 1000 bytes and the transmission rate at the sender is 80 Kbps (1Kbps = 1000 bits/second). Size of an acknowledgement is 100 bytes and the transmission rate at the receiver is 8 Kbps. The one-way propagation delay is 100 milliseconds. Assuming no frame is lost, the sender throughput is __________ bytes/second.
  • 2500
  • 2000
  • 1500
  • 500

Question 64

The following function computes the maximum value contained in an integer array p[] of size n (n >= 1) 
 

C
int max(int *p, int n)
{
    int a=0, b=n-1;
    while (__________)
    {
        if (p[a] <= p[b])
        {
            a = a+1;
        }
        else
        {
            b = b-1;
        }
    }
    return p[a];
}

The missing loop condition is
 

  • a != n
     

  • b != 0
     

  • b > (a + 1)
     

  • b != a
     

Question 65

Consider the following proposed solution for the critical section problem. There are n processes: P0 ...Pn−1. In the code, function pmax returns an integer not smaller than any of its arguments. For all i, t[i] is initialized to zero. deadlock Which one of the following is TRUE about the above solution?
  • At most one process can be in the critical section at any time
  • The bounded wait condition is satisfied
  • The progress condition is satisfied
  • It cannot cause a deadlock

There are 65 questions to complete.

Last Updated :
Take a part in the ongoing discussion