What is Computer Science?
When you hear the words “computer science”, what comes to mind? Do you think of computer programming – neon text on a black screen? Do you think of algorithms and equations scribbled on a whiteboard?
What is a Computer and What is Computer Programming?
In everyday speech, the word computer usually refers to laptops and desktops, like the one you’re reading these notes on. However, in reality, a computer is a much more general concept and most computers hardly resemble laptops.

Introduction to Computer Science

What is Computer Science?

When you hear the words “computer science”, what comes to mind? Do you think of computer programming – neon text on a black screen? Do you think of algorithms and equations scribbled on a whiteboard? Perhaps, when you hear “computer science”, you think of computer and phone applications, websites and video games: WhatsApp, FIFA 18, PhotoShop. Maybe you think of computers that drive, beat us at board games and make sense of language. Maybe you’ve seen the power of molecular dynamics simulation and you think of biology or chemistry. Or when you hear computer science you think of art – personally, I often think of this Pixar short and marvel at the unbelieavable computer rendering of the ocean – or music made by instruments that could only be forged with code. Maybe you think of goal line technology, applications that track your fitness, or statistical models that predict the outcomes of football tournaments. Perhaps you’re concerned about all the personal information that you hand over to Facebook and you think of the recent Facebook-Cambridge Analytica fiasco. When you hear computer science you might think of the economic implications of automation and its impact on inequality. Or maybe, when someone says computer science you don’t really think of anything at all. The thing is, computer science is not one of these things more than any another – it is all of them and much more.

Simply put, computer science is the art of using computers to solve problems. Computers can be used to solve a remarkably diverse set of problems, and that is why the visions of computer science listed above are so varied. The bottom line is: if we are getting a computer to solve a problem that it couldn’t before, then we are practicing computer science – it doesn’t matter what that problem is. So, as you begin this course, we’d recommend that you don’t dwell too much on preconceived notions of what you think computer science is or isnt. Rather, come with an open mind and along the way consider: what problems would I like a computer to solve?

What is a Computer and What is Computer Programming?

Let’s nail down exactly what we mean when we say “computer”. In everyday speech, the word computer usually refers to laptops and desktops, like the one you’re reading these notes on. However, in reality, a computer is a much more general concept and most computers hardly resemble laptops. The most powerful computers in the world, like IBM’s Summit supercomputer, can take up a full-room’s worth of space. Other computers are incredibly small and specialized, like the computer inside a pacemaker. Computers show up in places you might not expect them: microwave ovens, digital watches, traffic lights, microscopes, and MRI machines all have computers embedded inside them. If most computers lack screens or keyboards and don’t resemble the computers to we’re familiar with, what makes them computers? What ties all of these machines together?

A computer is a programmable, information-processing machine. It consists of a few physical components that allow it to perform four basic functions:

  1. Input information

    This is how the computer gets information from the world. We input information into our computers through our keyboard when we type. We’re also inputting information into computers when we use a video camera or microphone. When we log onto a website, our computer receives input from an internet connection. Computers also receive input from permanent storage devices like hard drives.

  2. Store information

    A computer can hold information in temporary memory for later access. A computer’s temporary memory is distinct from its permanent storage (i.e. hard drive, USB drive). When the computer is turned off, this memory dissapears, but it can be accessed much more rapidly than the information stored in a hard drive or USB drive.

  3. Process information

    A computer processes the information stored in memory. How it processes that information is dictated by a set of basic instructions provided by the user. The component of a computer responsible for processing information is called the central processing unit (CPU). The CPU reads the program, fetches information from memory, and processes that information as it was instructed to. What does this “processing” consist of? In general, the CPU is only capable of executing very simple operations: adding or subtracting numbers, copying or moving information, or evaluating numbers for equality. By linking these simple operations together, computer programmers can get the computer to perform challenging tasks.

  4. Output information

    For a computer to be useful to us, it must output newly-processed information. A laptop computer outputs information through a computer screen or speakers. Computers also output information to other computers via the internet.

Inside a computer there is typically at least one component for each of these four fundamental functions – input, output, store, and process. The four components are outlined in the figure below. The arrows indicate how information flows is passed through the computer.

More than anything else, what distinguishes computers from other machines is that they are programmable. In other words, without changing a computer’s physical design, we can get it to perform new tasks by following a new set of written instructions. That set of instructions is called a computer program and the act of writing the instructions is computer programming.

Computer programs are written in programming languages. A programming language is a precise language used to specify instructions to the computer.There are many, many programming languages – perhaps you’ve heard of a few like C++, Java or Python. Each consists of a set of rules and syntax that a programmer must follow in order to be understood by the computer.