ArticleslgStudy

computer science

Computer network programming

Computer network programming is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Computer network programming rather than just read about it. In short: Computer network programming involves writing computer programs that enable processes to communicate with each other across a computer network. Connection-oriented and connectionless communications Very generally, most of communications can be divided into connection-oriented, and connectionless.

Key takeaways

  • Computer network programming belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Computer network programming to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Computer network programming from memory before moving on to harder problems.

Reference excerpt

Computer network programming involves writing computer programs that enable processes to communicate with each other across a computer network.

Connection-oriented and connectionless communications Very generally, most of communications can be divided into connection-oriented, and connectionless. Whether a communication is connection-oriented or connectionless, is defined by the communication protocol, and not by application programming interface (API). Examples of the connection-oriented protocols include Transmission Control Protocol (TCP) and Sequenced Packet Exchange (SPX), and examples of connectionless protocols include User Datagram Protocol (UDP), "raw IP", and Internetwork Packet Exchange (IPX).

Clients and servers

For connection-oriented communications, communication parties usually have different roles. One party is usually waiting for incoming connections; this party is usually referred to as "server". Another party is the one which initiates connection; this party is usually referred to as "client". For connectionless communications, one party ("server") is usually waiting for an incoming packet, and another party ("client") is usually understood as the one which sends an unsolicited packet to "server".

Popular protocols and APIs Network programming traditionally covers different layers of OSI/ISO model (most of application-level programming belongs to L4 and up). The table below contains some examples of popular protocols belonging to different OSI/ISO layers, and popular APIs for them.

See also Software-defined networking Infrastructure as code Site reliability engineering DevOps

References W. Richard Stevens: UNIX Network Programming, Volume 1, Second Edition: Networking APIs: Sockets and XTI, Prentice Hall, 1998, ISBN 0-13-490012-X

Worked examples

Example 1 — a first encounter with Computer network programming

Start with the simplest possible case. Write down what Computer network programming claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Computer network programming before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Computer network programming ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Computer network programming

In research
Computer network programming appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Computer network programming in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Computer network programming is common in secondary-school and first-year university syllabi. It links to neighbouring topics Computer network engineering, Computer programming, Inter-process communication, so understanding it makes those chapters shorter.
In everyday life
Look for Computer network programming outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Computer network programming” →

How to study Computer network programming in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Computer network programming means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Computer network programming out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Computer network programming in simple terms?

Computer network programming involves writing computer programs that enable processes to communicate with each other across a computer network. Connection-oriented and connectionless communications Very generally, most of communications can be divided into connection-oriented, and connectionless.

Why does Computer network programming matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Computer network programming?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Computer network programming.

Tags

  • Computer network engineering
  • Computer programming
  • Inter-process communication

Keep exploring