Programming Flashcards
What is a constant?
value that stays the same throughout the running of the program.
What is a variable?
A name/symbol which represents a value in a
program and .points to a memory location: A value that changes during the programs execution.
What is a sequence?
one instruction after another
What is a selection?
A condition is used to decide whether code should be executed (if/case)
What is an iteration?
A process or sequence that is repeated usually in the form of a loop (for/loop/repeat)
code is executed repeatedly
What are two examples of low level language?
assembly language and machine code
A translator is needed to…
converts high-level languages into machine code. (compilers and interpreters)
What does an IF/THEN/ELSE statement do?
allows you to select an option from several options
What does a CASE statement do?
for coding multiple choices in a program
What is an algorithm?
a process or set of rules to be followed to complete a task e.g. flow charts or pseudocode
What is high level code?
code which is close to human languages e.g. python
What is Machine code?
a language directly understood by the CPU, instructions are represented by a string of bits
What is an interpreter and a compiler?
converts high level code into machine code
What is an assembler?
coverts assembly language into machine code
What is a for loop?
repeats a group of steps a specified number of times
What is a repeat loop?
controlled by condition at the end of the loop
What is a while loop?
controlled by a condition at the start of the loop
What is the difference between a string and a character data type?
- string contains multiple characters
What is a real(float) number?
a number with a decimal point
What is a boolean data type?
a true/false yes/no 0/1 data type
What is a syntax error?
a problem with the language that the translators do not understand e.g. spelling
What is a logical error?
The program is written to do something other than what the programmer intended
e.g. an infinate loop, division by 0 or a wrong data type
What is integrated development environment (IDE)?
a software package that helps you write code more easily
e.g. colour coding key words and numbering lines
What is run-time environment?
provides the screen +feedback when you try to run a program
What is auto-documentation?
the computer uses the data as well as comments to generate a text file
What is an array?
a list
What is the difference between compilers and interpreters?
a compiler runs the object code whereas an interpreter runs the source code
What is a compiler used for?
distribution of software
What is a interpreter used for?
development of software
What is an Opcode?
single instruction that can be executed by the CPU.
What is an Operand?
supplies the data needed for the operation code
What is an array?
An array is a data structure that contains a group of elements. each individual variable is given an index which it is referred to within the array.
How does the IDE help the programmer correct errors?
error messages/ translator diagnostics produced when translating by the computer
an editor allows you enter the corrected code
tries to tell you when the errors are by highlight the errors
What does the editing tool do in the IDE?
- allows you to enter program code
- colour codes key words
- auto-completes codes as you type
What does the compiler tool do in the IDE?
translates the code into machine code
What does the de-bugging tool do in the IDE?
highlights errors