Interview Q&A / Computer Networks

INTERVIEW Q&A · 55 QUESTIONS

Computer Networks interview questions

What happens when you open a website, TCP vs UDP, DNS and HTTP.

  1. How do Cache-Control and ETag let a browser reuse a response?

    Cache-Control: max-age tells the browser how long it may reuse a response without asking. After that, the browser can revalidate with If-None-Match and the ETag; if nothing changed, the server replies 304 Not Modified with no body.

    IntermediateQuick answer1 min read
  2. What are the main differences between HTTP/1.1 and HTTP/2?

    HTTP/2 uses a binary format, multiplexes many requests over a single TCP connection, compresses headers with HPACK and allows prioritisation. HTTP/1.1 is plain text and handles one request at a time per connection, so browsers open several connections instead.

    IntermediateQuick answer1 min read