Computer Science & Applications (Paper 2) (Code 87) · Unit 9 of 10

Data Communication & Computer Networks

कंप्यूटर नेटवर्क

Unit overview: the topics below, with their summaries, are the syllabus for this unit. The comprehensive note further down covers every topic in full — explanations, definitions, worked examples, tables, exam points and practice questions — and the short revision note after it is only a quick recap. Standalone one-topic learning pages are not built yet — every topic on this page is covered in the notes and the practice questions below, and each topic card links to those sections.

Premium chapters for this unit

OSI & TCP/IP models → premium chapter · free preview · ~24 min · 4 practice questions

Routing, switching & protocols → premium chapter · free preview · ~26 min · 4 practice questions

Network security basics → premium chapter · free preview · ~26 min · 4 practice questions

Topics checklist — with weightage (platform estimate from past-question frequency, not an NTA guarantee)

OSI & TCP/IP models

High weightage

Layer-by-layer: what each layer actually does.

Routing, switching & protocols

High weightage

IP addressing, subnetting, TCP vs UDP, DNS, HTTP.

Network security basics

Medium

Firewalls, cryptography basics, VPN, wireless.

Comprehensive unit note · ~22 min read

Computer networks exist to move data reliably between machines that may be built by different vendors, run different software, and sit far apart. Data communication is the exchange itself: a sender encodes a message into signals, a channel carries those signals, and a receiver decodes them back into the message. Everything in this unit is a refinement of that simple picture. Noise corrupts signals, links have limited capacity, many senders share one medium, addresses must be unique, routes must be chosen, and some data must stay secret. Each layer of a network model solves one part of this problem and hides its details from the layers above it. The layered idea is the key to the whole unit. The sender passes data down through layers, each adding its own header, and sometimes a trailer, in a process called encapsulation. The receiver strips those headers off in reverse order. Because each layer offers a service to the layer above and uses only the service of the layer below, a change in one layer, such as replacing copper cable with fibre, does not force a rewrite of the applications above it. Two models organise these layers: the seven-layer OSI model, which is the reference for teaching and for naming devices and protocols, and the four-layer TCP/IP model, which is the model the real internet actually runs on. Questions frequently ask you to place a device or protocol in the right layer, so learn the layers by function, not by memorised lists alone. From the physical signals upward, the unit follows data through framing and error control on a single link, addressing and routing across many links, reliable end-to-end delivery, and finally the application protocols users meet directly, such as DNS, HTTP, mail, and DHCP. It ends with security: how cryptography, firewalls, and VPNs protect data that travels over networks nobody fully controls. Read each section by asking, for every mechanism, what problem it solves, what it costs, and what happens when it fails.

Learning objectives

  • Explain the function of each OSI and TCP/IP layer and place common devices and protocols in the correct layer.
  • Apply framing, parity, CRC, stop-and-wait, and sliding-window ideas to detect errors and control flow on a link.
  • Perform IPv4 subnetting and CIDR calculations, including usable-host counts and subnet addresses.
  • Compare distance-vector and link-state routing and explain NAT, ARP, and IPv6 addressing.
  • Contrast TCP and UDP, explain the three-way handshake, and describe flow and congestion control.
  • Describe DNS, HTTP, FTP, SMTP, and DHCP and explain how each one is used.
  • Compare symmetric and asymmetric cryptography, digital signatures, firewalls, VPNs, and common network attacks.

Overview: How a Network Moves Data

Start with one message, for example a web page request. The application creates the message. The transport layer may split it into segments and number them. The network layer adds source and destination IP addresses and creates packets. The data-link layer adds hardware addresses and a frame check sequence, producing frames. The physical layer turns frames into bits and then into electrical, optical, or radio signals. Switches forward frames inside a local network using hardware addresses, while routers forward packets between networks using IP addresses. At the destination the process reverses: signals become bits, frames are checked and stripped, packets are routed to the right host, segments are reassembled in order, and the application receives the original message. Two ideas recur throughout. First, an address at one layer does not replace an address at another: IP addresses identify hosts across networks, while MAC addresses identify interfaces on a single link, and port numbers identify applications inside a host. Second, reliability can be built at different layers, but each mechanism costs bandwidth, delay, or complexity, so protocols choose the level of reliability their users actually need.

OSI & TCP/IP models

The OSI model has seven layers, from bottom to top: Physical, Data Link, Network, Transport, Session, Presentation, and Application. The Physical layer deals with bits, signalling, cables, connectors, and data rates: it moves raw bits, nothing more. The Data Link layer organises bits into frames, controls access to a shared medium, detects errors, and delivers frames between neighbours on the same link; switches and bridges work here. The Network layer delivers packets across multiple networks, using logical addressing and routing; routers work here. The Transport layer delivers segments end to end between processes, providing reliability, ordering, and flow control when required. The Session layer manages dialogues between applications, including establishing, maintaining, and ending sessions. The Presentation layer handles translation, encryption, and compression so that different systems can understand the same data. The Application layer provides network services directly to user programs, such as web browsing, mail, and file transfer. A useful memory aid is that the lower three layers are mainly about moving data, the upper three are mainly about the application, and transport bridges the two.

The TCP/IP model has four layers: Network Access (also called Link), Internet, Transport, and Application. The Network Access layer combines the OSI physical and data-link functions. The Internet layer corresponds to the OSI network layer and is built around IP. The Transport layer is TCP or UDP. The Application layer combines the OSI session, presentation, and application layers, and holds protocols such as HTTP, DNS, FTP, SMTP, and DHCP. TCP/IP won in practice because it was simpler, was tied to working implementations, and grew with the internet, while OSI remains the standard vocabulary for exams and for describing where a device or protocol sits. A repeater works at the physical layer, a hub also at the physical layer, a bridge and switch at the data link layer, a router at the network layer, and a gateway can operate up to the application layer. Encapsulation explains the names: data becomes a segment at transport, a packet at network, a frame at data link, and bits at physical. In TCP/IP, the same idea is often described as segment, packet, frame, and bits.

The physical layer must also handle how bits are represented and timed. Bandwidth is the capacity of a channel, throughput is the rate actually achieved, and latency includes propagation delay, transmission delay, queuing delay, and processing delay. Guided media include twisted pair, coaxial cable, and fibre-optic cable; unguided media include radio, microwave, and infrared. Fibre offers high bandwidth and immunity to electromagnetic interference but is harder to install and splice. Twisted pair is cheap and common for local networks but is limited in distance and bandwidth. The data-link layer then faces framing: the receiver must know where one frame ends and the next begins. Fixed-size framing is simple but wasteful for variable data; variable-size framing uses length fields or flag delimiters, with character or bit stuffing to keep a flag pattern from appearing inside the data by accident.

Routing, switching & protocols

Error detection starts from a simple fact: noise can flip bits, but the receiver cannot ask the sender what was intended unless extra information is present. Parity adds one redundant bit so that the total number of ones is even (even parity) or odd (odd parity). A single-bit error changes the parity and is detected, but a two-bit error leaves parity unchanged and escapes, and parity cannot say which bit is wrong. A checksum sums data words and sends the complement of the sum; the receiver recomputes it. A cyclic redundancy check, CRC, treats the data as a polynomial and divides it by a generator polynomial, sending the remainder; the receiver repeats the division and expects a zero remainder. CRC detects all single-bit errors, all burst errors shorter than the generator length, and most longer bursts, which is why it is used in Ethernet and many other links. Detection is not correction: on most links the receiver discards the bad frame and the sender retransmits after a timeout, using an acknowledgement scheme.

Flow control stops a fast sender overwhelming a slow receiver. In stop-and-wait, the sender transmits one frame and waits for an acknowledgement before sending the next. It is simple and correct, but inefficient on links with long propagation delay, because the channel idles while the sender waits. The sliding window generalises it: the sender may have several unacknowledged frames outstanding, up to the window size, and the receiver advertises how much buffer space remains. Go-Back-N retransmits the whole window from the first lost frame, while selective repeat retransmits only the lost frames but needs more buffer and logic at the receiver. Window size is also limited by sequence numbers: with n-bit sequence numbers, Go-Back-N can use at most 2 to the power n minus 1 outstanding frames, otherwise an acknowledgement becomes ambiguous. On a shared medium, medium access control decides who may transmit. Pure ALOHA lets stations transmit whenever they like and retransmits after collisions; slotted ALOHA restricts transmissions to time slots and roughly doubles efficiency. CSMA listens before transmitting, and CSMA/CD, used in classic Ethernet, also detects collisions and backs off for a random time. Modern switched Ethernet largely avoids collisions by giving each station its own switch port and using full duplex, but the CSMA/CD idea is still examined. Ethernet frames carry destination and source MAC addresses, a type field, data, and a CRC. ARP maps a known IP address to an unknown MAC address on the local network by broadcasting a request: who has this IP address, and the owner replies with its MAC address. RARP and DHCP later reverse or automate address assignment.

The network layer is where internetworking happens. IPv4 addresses are 32 bits, written as four decimal octets, and divided into network and host parts. Classes A, B, and C are historical, but modern routing uses classless addressing, CIDR, where a prefix length such as /26 states how many bits belong to the network part. Subnetting borrows host bits to create smaller networks. For a /26, 32 minus 26 leaves 6 host bits, giving 64 addresses in total and 62 usable hosts, because the all-zero address is the network address and the all-ones address is the broadcast address. Subnet masks are written in the same dotted form: /26 is 255.255.255.192. IPv6 addresses are 128 bits, written in hexadecimal groups, and were introduced because IPv4 addresses were running out and because IPv6 simplifies headers, supports autoconfiguration, and builds in support for extension headers and, in principle, security. IPv6 has no broadcast address in the IPv4 sense; it uses multicast and anycast instead. NAT lets many private hosts share one public address by rewriting addresses and ports at the border router; it conserves public addresses but breaks true end-to-end connectivity and complicates some protocols.

Routing algorithms decide the next hop for each packet. Distance-vector routing, exemplified by RIP, has each router tell its neighbours its distance to every destination; routers update by taking the minimum over neighbours. It is simple but slow to converge and can suffer the count-to-infinity problem, where bad news about a failed link circulates and increments slowly; split horizon and poison reverse reduce the problem. Link-state routing, exemplified by OSPF, has each router learn the full topology by flooding link-state advertisements and then run Dijkstra shortest-path algorithm locally. It converges faster and avoids count-to-infinity, but needs more memory and processing and careful flooding. Routing inside one autonomous system uses interior protocols such as RIP and OSPF; routing between autonomous systems uses BGP, a path-vector protocol. Switching is the local counterpart: a switch learns MAC addresses from source addresses in incoming frames, builds a forwarding table, and forwards each frame only to the port where the destination lives, flooding only when the destination is unknown or the frame is broadcast.

At the transport layer, TCP is connection-oriented, reliable, ordered, and byte-stream based, while UDP is connectionless, unreliable, and message based. TCP establishes a connection with a three-way handshake: the client sends SYN, the server replies SYN-ACK, and the client sends ACK; connection teardown uses FIN exchanges. Reliability comes from sequence numbers, acknowledgements, retransmission timers, and checksums. Flow control uses the receiver advertised window, and congestion control uses slow start, congestion avoidance, fast retransmit, and fast recovery: the sender probes for available capacity and backs off when loss suggests congestion. UDP skips all of this, so it is faster and simpler and is used where occasional loss is acceptable or where the application handles reliability itself, such as DNS queries, streaming, and real-time media. Port numbers identify the application: well-known ports include 80 for HTTP, 443 for HTTPS, 53 for DNS, 25 for SMTP, 21 for FTP, and 67 and 68 for DHCP. The application layer then provides the services themselves. DNS translates names to IP addresses through a hierarchy of root, top-level, and authoritative servers, with resolvers caching answers. HTTP is the request-response protocol of the web; HTTPS adds TLS encryption over the same model. FTP transfers files over separate control and data connections. SMTP sends mail between servers, while POP and IMAP let users retrieve it. DHCP automates address assignment, handing out an IP address, subnet mask, gateway, and DNS servers, typically through discover, offer, request, and acknowledgement messages.

Network security basics

Security in networks rests on four goals: confidentiality, so only authorised parties read data; integrity, so data is not altered unnoticed; authentication, so parties are who they claim to be; and availability, so services keep working. Cryptography provides the first three. In symmetric cryptography, the same secret key encrypts and decrypts; it is fast and suitable for bulk data, but the key must be shared securely beforehand, and a network of many users needs many keys. In asymmetric cryptography, each party has a public key anyone may use to encrypt, and a private key only the owner holds to decrypt; key distribution becomes easy, but the mathematics is slower, so in practice systems use asymmetric methods to exchange a symmetric session key and then use the symmetric key for the bulk data. The classic asymmetric example is RSA: choose two large primes, multiply them to form the modulus, derive a public exponent and a private exponent that are inverses under the relevant modular arithmetic, publish the public pair, and keep the private exponent secret. Security rests on the difficulty of factoring the modulus back into its primes. A digital signature reverses the roles: the sender encrypts a hash of the message with the private key, and anyone can verify it with the public key, proving both the sender and that the message was not changed. A hash function itself produces a fixed-size digest; a good hash is one-way and collision-resistant, so finding two different messages with the same digest is infeasible. A message authentication code adds a shared secret to a hash so the receiver can also be sure of the sender.

A firewall is a barrier between a trusted internal network and an untrusted external network. Packet-filtering firewalls inspect headers such as source, destination, port, and protocol and allow or deny packets by rule; they are fast but cannot understand application content and are hard to configure correctly. Stateful firewalls track the state of connections and allow return traffic only for connections that were legitimately opened. Application-level gateways and proxies inspect traffic at higher layers and can enforce finer policy but add latency. A VPN creates an encrypted tunnel over a public network so that remote users or offices can communicate as if on a private network; tunnelling protocols encapsulate and encrypt the inner packets. Wireless security has its own history: WEP used a short key and a weak initialisation-vector scheme and is now considered broken; WPA improved key handling, and WPA2 and WPA3 use stronger encryption and authentication and should be preferred. Common attacks must be recognised by name and mechanism. Eavesdropping intercepts traffic; a man-in-the-middle attacker sits between two parties and relays or alters messages; spoofing forges a source address or identity; a denial-of-service attack floods a target so legitimate users cannot get service, and a distributed version uses many compromised machines. Phishing tricks users into revealing credentials, SQL injection and cross-site scripting attack web applications rather than the network itself, and malware such as worms spreads across networks without user action. Defence is layered: encryption for confidentiality, authentication for identity, firewalls and intrusion detection for boundaries, patching for known flaws, and user education for social engineering. No single mechanism covers all four security goals, and exam questions often test exactly that distinction.

Key definitions

  • Encapsulation: The process by which each layer adds its own header, and sometimes a trailer, to data received from the layer above, so the receiver can strip headers in reverse order.
  • MAC address: A hardware address, usually 48 bits, that identifies a network interface on a single local link; used by switches and Ethernet frames.
  • IP address: A logical address that identifies a host across networks; 32 bits in IPv4 and 128 bits in IPv6.
  • Parity bit: One redundant bit added to a block of data so the total number of ones is even or odd; detects single-bit errors but cannot correct them.
  • CRC: A cyclic redundancy check: the remainder left when data, treated as a polynomial, is divided by a generator polynomial; the receiver repeats the division and expects a zero remainder.
  • Sliding window: A flow-control method in which the sender may have several unacknowledged frames outstanding, up to a window size advertised by the receiver.
  • ARP: Address Resolution Protocol: maps a known IP address to the corresponding MAC address on a local network by broadcast request and unicast reply.
  • Subnet mask: A 32-bit value whose ones mark the network part of an IPv4 address; for example, a /26 prefix corresponds to 255.255.255.192.
  • CIDR: Classless Inter-Domain Routing: addressing in which the network prefix length is stated explicitly, such as /26, instead of using fixed address classes.
  • NAT: Network Address Translation: rewriting of private IP addresses and ports to a public address at a border router, allowing many hosts to share one public address.
  • Distance-vector routing: Routing in which each router periodically shares its distance to each destination with its neighbours and keeps the smallest distance heard.
  • Link-state routing: Routing in which each router floods information about its own links, learns the full topology, and runs Dijkstra algorithm to find shortest paths.
  • Three-way handshake: The SYN, SYN-ACK, ACK exchange by which TCP establishes a connection and synchronises initial sequence numbers before data transfer.
  • DNS: Domain Name System: the hierarchical, distributed system that translates human-readable host names into IP addresses.
  • Symmetric cryptography: Cryptography in which the same secret key encrypts and decrypts; fast for bulk data but requires secure key distribution.
  • Asymmetric cryptography: Cryptography using a public key for encryption and a private key for decryption, so keys can be distributed openly while decryption stays secret.
  • Digital signature: A private-key encryption of a message hash that lets anyone with the public key verify the sender and detect alteration of the message.
  • Firewall: A device or software barrier that filters network traffic between trusted and untrusted networks according to a rule set.

Formulas

  • Usable hosts in an IPv4 subnet = 2^h - 2, where h is the number of host bits; the two subtracted addresses are the network address and the broadcast address.
  • Total addresses in a subnet = 2^h, where h = 32 - prefix length for IPv4.
  • Stop-and-wait efficiency = 1 / (1 + 2a), where a = propagation delay / transmission delay.
  • Maximum Go-Back-N window with n-bit sequence numbers = 2^n - 1 frames.
  • Transmission delay = frame length in bits / link data rate in bits per second.

Worked examples

Example 1: Subnet the network 192.168.1.0/26 into its subnets. How many subnets are created from a /24 base, how many hosts per subnet, and what are the first two subnet address ranges?

From a /24 base to /26 borrows 26 - 24 = 2 bits, so the number of subnets is 2^2 = 4. Host bits are 32 - 26 = 6, so each subnet has 2^6 = 64 addresses and 64 - 2 = 62 usable hosts. The block size is 256 - 192 = 64, since the /26 mask is 255.255.255.192. The first subnet is 192.168.1.0 to 192.168.1.63, with network address 192.168.1.0, broadcast 192.168.1.63, and usable hosts 192.168.1.1 to 192.168.1.62. The second subnet is 192.168.1.64 to 192.168.1.127, with network address 192.168.1.64, broadcast 192.168.1.127, and usable hosts 192.168.1.65 to 192.168.1.126. The remaining subnets start at 192.168.1.128 and 192.168.1.192.

Example 2: A sender uses even parity and transmits the 7-bit data 1011001. What parity bit is appended, and what happens if one bit flips in transit?

Count the ones in 1011001: there are four ones. Even parity requires the total number of ones, including the parity bit, to be even, so the parity bit is 0, giving 10110010. If any single bit flips, the count of ones becomes odd, the receiver recomputes parity, finds it odd instead of even, and detects the error. It cannot tell which bit flipped, so it discards the frame and relies on retransmission. If two bits flip, the count returns to even and the error escapes detection, which is the key limitation of parity.

Example 3: A link has a transmission delay of 1 ms per frame and a one-way propagation delay of 24.5 ms. What is the efficiency of stop-and-wait on this link?

Here a = propagation delay / transmission delay = 24.5 / 1 = 24.5. Stop-and-wait efficiency = 1 / (1 + 2a) = 1 / (1 + 49) = 1 / 50 = 0.02, or 2 percent. The sender spends most of the time waiting for the acknowledgement to return, which shows why sliding windows with many outstanding frames are needed on long-delay links such as satellite links.

OSI model versus TCP/IP model

AspectOSI modelTCP/IP model
LayersSeven: physical to applicationFour: network access, internet, transport, application
StatusReference model for teaching and descriptionModel actually used by the internet
Session and presentationSeparate layersMerged into the application layer
Origin of designDesigned before widespread implementationGrew from working protocols

TCP versus UDP

AspectTCPUDP
ConnectionConnection-oriented, handshake firstConnectionless, no handshake
ReliabilityReliable, ordered, retransmits lost dataUnreliable, no retransmission guarantee
Speed and overheadSlower, larger header and stateFaster, small header, low overhead
Typical usesWeb, mail, file transferDNS queries, streaming, real-time media

Symmetric versus asymmetric cryptography

AspectSymmetricAsymmetric
KeysOne shared secret keyPublic key plus private key
SpeedFast, suitable for bulk dataSlower, used mainly for key exchange and signatures
Key distributionHard: key must be shared secretly firstEasy: public key can be shared openly
Number of keysGrows fast with number of usersEach user needs one key pair

Distance-vector versus link-state routing

AspectDistance-vectorLink-state
KnowledgeOnly distances reported by neighboursFull network topology
ExampleRIPOSPF
ConvergenceSlower, risk of count-to-infinityFaster, no count-to-infinity
CostSimple, low processingMore memory and processing

Diagrams (described)

Encapsulation stack, top to bottom: Application data, then transport header added to form a segment, then network header added to form a packet, then data-link header and trailer added to form a frame, then physical layer converts the frame to bits and signals. The receiver strips headers in reverse order.

Three-way handshake flow: Client sends SYN, server replies SYN-ACK, client sends ACK, then data flows in both directions. Teardown uses FIN exchanges in each direction.

Subnetting diagram for 192.168.1.0/26: the 32-bit address is split into a 26-bit network part and a 6-bit host part; the 6 host bits give blocks of 64 addresses starting at 0, 64, 128, and 192 in the last octet.

Firewall placement diagram: internal hosts connect to a switch, the switch connects through the firewall to the border router, and the router connects to the internet; the firewall filters traffic crossing between the trusted and untrusted sides.

Exam points

  • OSI layer order from bottom to top: Physical, Data Link, Network, Transport, Session, Presentation, Application.
  • Routers work at the network layer, switches and bridges at the data link layer, hubs and repeaters at the physical layer.
  • TCP is reliable and connection-oriented; UDP is unreliable and connectionless.
  • A /26 subnet has 64 addresses and 62 usable hosts; a /24 has 256 addresses and 254 usable hosts.
  • ARP resolves IP addresses to MAC addresses; DNS resolves names to IP addresses; DHCP assigns addresses automatically.
  • CRC detects burst errors far better than single parity, which misses any even number of bit flips.
  • Go-Back-N retransmits the whole window from the lost frame; selective repeat retransmits only lost frames.
  • Well-known ports: HTTP 80, HTTPS 443, DNS 53, SMTP 25, FTP 21, DHCP 67 and 68.
  • RSA security rests on the difficulty of factoring a product of two large primes.
  • WEP is broken and should not be chosen over WPA2 or WPA3 in any security question.

Common mistakes

  • Mistake: saying a switch routes between networks. Correction: a switch forwards frames within one network using MAC addresses; a router forwards packets between networks using IP addresses.
  • Mistake: counting the network and broadcast addresses as usable hosts. Correction: always subtract 2 from the total addresses in a subnet.
  • Mistake: claiming parity can correct errors. Correction: parity detects single-bit errors only; correction needs stronger codes or retransmission.
  • Mistake: placing TCP/IP session and presentation functions in separate TCP/IP layers. Correction: TCP/IP merges them into the application layer; only OSI keeps them separate.
  • Mistake: calling UDP reliable because an application over UDP retries. Correction: UDP itself remains unreliable; any reliability comes from the application above it.
  • Mistake: confusing ARP with DNS. Correction: ARP maps IP to MAC on a local link, while DNS maps names to IP addresses across the internet.
  • Mistake: thinking a firewall alone guarantees security. Correction: a firewall filters boundary traffic but does not fix unpatched software, weak passwords, or phishing.
  • Mistake: describing a digital signature as encryption of the whole message with the private key. Correction: in practice the sender signs a hash of the message, which is efficient and still detects any alteration.

Practice questions from this note (original practice — not official PYQs)

Checking login…

Quick revision: Layer order first: OSI physical, data link, network, transport, session, presentation, application; TCP/IP network access, internet, transport, application. Remember devices by layer: hub and repeater physical, switch and bridge data link, router network. Reliability tools: parity detects single-bit errors, CRC detects bursts, stop-and-wait is simple but idle on long delays, sliding windows keep the pipe full, Go-Back-N resends the window, selective repeat resends only lost frames. Subnet maths: host bits = 32 minus prefix, total = 2 to the host bits, usable = total minus 2. Routing: distance-vector shares distances and risks count-to-infinity, link-state floods topology and runs Dijkstra. Transport: TCP handshakes with SYN, SYN-ACK, ACK and controls flow and congestion; UDP is fast and unreliable. Application ports: HTTP 80, HTTPS 443, DNS 53, SMTP 25, FTP 21, DHCP 67 and 68. Security: symmetric is fast but needs shared secrets, asymmetric solves distribution but is slow, signatures sign a hash with the private key, firewalls filter at boundaries, VPNs tunnel encrypted traffic, and WEP is broken.

Unit revision note (quick recap)

Networks move bits reliably between machines that may fail, delay or reorder packets. Layers separate concerns so each layer solves one problem well.

Learning objectives

  • Explain OSI/TCP-IP layers
  • Subnet and choose protocols
  • Explain routing and security basics

Key concepts

  • Network layer: Layer 3: IP addressing and routing between networks.
  • TCP vs UDP: TCP is connection-oriented, ordered and reliable. UDP is connectionless, fast, loss-tolerant.
  • Subnet usable hosts: 2^(host bits) − 2 (network and broadcast addresses excluded).
  • DNS: Maps names to IP addresses, hierarchically.

Formulas

  • Usable hosts = 2^h − 2, where h = host bits

Worked examples

  • 192.168.1.0/26: host bits = 6, usable = 64 − 2 = 62.

Exam points

  • OSI order: Physical, Data Link, Network, Transport, Session, Presentation, Application.
  • HTTP is application layer; TCP is transport; IP is network; Ethernet is data link.

Common mistakes

  • Counting network and broadcast addresses as usable hosts in subnet questions.

Quick revision: Models, addressing, subnetting, routing, transport, application protocols, security basics.

Practice questions from the whole unit bank (28 in the bank)

This unit's practice bank — the note above has its own smaller practice set drawn from the same bank, so a question can appear in both lists. The list below shows the free sample or the full bank depending on your plan.

Checking login…

Related tests

Unit test for this unit (28 bank questions, 34 min) · Full Mock — CS Paper 2 (100 questions) · Combined 150-question mock (180 min). All +2 per correct, no negative marking.

Revision summary

Models, addressing, subnetting, routing, transport, application protocols, security basics.

After revising, take the unit test above, then check your unit-wise report on the Dashboard to find weak topics.