Hardware, software, languages and translators :)
Human-readable instructions are encoded in a language that humans can use and understand, while machine-readable instructions are in a language that computers understand, and are in binary code.
Languages are also described as high level or low level. Low-level languages, such as assembly language, more closely reflect the mechanical workings of the CPU.
A computer's CPU only understands (executes) series of binary numbers - so all programming languages are converted into binary code. Low-level instructions can be processed more speedily than high-level languages, but they are more difficult for people to read and write.
Translators - usually included within programming software - convert high-level code into machine code. Translators are assemblers, interpreters or compilers.
An assembler translates assembly language into machine code. Assembly language is a low-level language written in mnemonics that closely reflects the operations of the CPU.
An interpreter translates code into machine code, instruction by instruction - the CPU executes each instruction before the interpreter moves on to translate the next instruction. Interpreted code will show an error as soon as it hits a problem, so it is easier to debug than compiled code.
An interpreter does not create an independent final set of source code - source code is created each time it runs. Interpreted code is slower to execute than compiled code.
Interpreted languages include JavaScript, PHP, Python and Ruby. Interpreted languages are also called scripting languages. These are ideal for using within dynamic web applications. They are used for client-side and server-side coding, as they are small programs that are executed within the browser.
A compiler translates the whole program into machine code before the program is run. It can be difficult to test individual lines of compiled code compared to interpreted languages as all bugs are reported after the program has been compiled.
The machine code is saved and stored separately to the high-level code. Compilation is slow but machine code can be executed quickly.
Computer systems consist of hardware and software. Hardware is the physical components of the computer, such as the central processing unit (CPU), hard disk, monitor, keyboard and mouse. Software is the programs that run on a computer.
Hardware is the physical components of a computer. Software is the programs that run on a computer.
A computer system requires both hardware and software to function. Aside from the internal components of a computer, additional hardware allows the user to communicate with the system through inputs and outputs. The table below shows some examples of input and output hardware.
The software in a computer system enables the hardware to function and the user to perform tasks. Software within a computer system is divided into two main types, system software and application software.
System software is any software that assists with the running or management of the computer system. This can include operating systems, security software and file management software.
pplication software is any software added to the system that enables the user to perform a task. For example, a word processor allows the user to type a document and a browser allows the user to view web pages.
Application software enables the user to perform a task. System software helps the user manage the computer system.
An operating system is a collection (or suite) of programs that manages and controls the computer. Operating systems have many functions:
- controlling hardware components
- managing processes
- managing the computer's memory
- managing input and output devices
- managing applications
- managing security