CS FundamentalsHardGATE CS
A leaky bucket holds at most 6 packets and sends at most 3 per tick. Each tick, arrivals are added first (any overflow beyond 6 is dropped), then up to 3 packets leave. Arrivals over 8 ticks are [5, 0, 7, 2, 0, 0, 3, 0]. How many packets are dropped, and how many leave in tick 4?
- A. 1 dropped; 3 leave in tick 4
- B. 4 dropped; 3 leave in tick 4
- C. 1 dropped; 2 leave in tick 4
- D. 0 dropped; 3 leave in tick 4
Correct answer: A. 1 dropped; 3 leave in tick 4
Queue after each tick: 5 → 2; 2 → 0 (sends 2); 0 + 7 = 7 > 6 so 1 is dropped, sends 3, leaving 3; 3 + 2 = 5, sends 3. Output per tick: [3, 2, 3, 3, 2, 0, 3, 0]. Total dropped 1.
More Computer Networks questions
- A switch's MAC table ages out entries after 300 s. Host H was learned on port 3 and then moved silently to port 7 without sending…
- 10.0.0.0/8 is divided into /22 subnets numbered from 0 in address order. Host 10.45.200.17 uses the mask 255.255.252.0. What is the number…
- An organisation needs three LANs with 1000, 500 and 250 hosts, carved with VLSM from ONE contiguous CIDR block. What is the longest prefix…
- A TCP sender transmits segments 1–8 back to back; segment 3 is lost and every other segment arrives. The receiver sends an ACK for every…
- A TCP Reno sender (RFC 5681 fast recovery) has cwnd = 16 MSS when the third duplicate ACK arrives. Four MORE duplicate ACKs arrive, and…
- Selective Repeat uses 4-bit sequence numbers with the largest window that is safe. Frames take 1 ms to transmit on a 2 Mbps link, the…