Basically How To Program A Computer

Terry Barnaby

Introduction

A computer is a machine that manipulates data according to a set of instructions. This is a simple introductory course on how to program a computer. I think it is quite important for people to have a basic understanding of how computers work and how they can be programmed. Much of what is taught today is used of particular computer programs such as word processors etc... A computer is much more than a passive word processor however. It is a sophisticated tool that can be programmed to perform simple or even complex tasks to aid ones work. In order to understand what a computer can really do you need to have a basic understanding as to how it works. This course aims to give that basic understanding and leads onto writing and modifying a simple game written in the Java computer language.

Electronics

Computers are fundamentally electronic devices. They use the flow of electricity in complex circuits in order to be able to input, compute, store and display information. A basic knowledge of electronics is useful to provide a basis for the understanding of computers.

Binary System

Computers are primarily number processing machines. In order to understand them it is useful to know how they deal with numbers. Due to there electronic heritage and the simplicity of binary numbers their processing is based on the binary number system.

Computer Forms

There are many type of computer in normal use today. These can be classified into a number of groups.

General Form of a computer

Computers perform calculations and other operations on numbers. A basic computer has the following components:

 ElectronicsTutorialDraw1

 

Computers perform a set of comands using the input data and memory and write results into the memory and/or output. The set of commands is called a program. The set of program commands can consist of oneof the following types:

Compuer

Look inside a Personal Computer

We will now look inside a typical PC and see what the components are.
http://pcsupport.about.com/od/insidethepc/ss/howitfits.htm

Computer Programs

Computer Languages

In order to instruct a computer to perform some task we need to give it a list of instructions to be performed. At the basic electronic level this will be a list of number codes called computer opcode's. As these are difficult to understand there have been written a number of human like languages designed to program a computer. These languages have been designed to be precise, non-ambiguous languages unlike conventional human languages in order to clearly define the set of instructions to be performed and deal with the data types involved. The computer is able to translate the text of these languages into the numeric opcode's the computer needs in order to be able to run. There are three basic forms of languages:

Simple example

This shows how to program a computer using the Java computer language in a simple teaching environment called Greenfoot.

Further Work

This is just a basic introduction. There are many sources for information on computer programming and many areas of knowledge involved.