Mindmap
Programming
Inhalt der Mindmap
Programming
High level languages
- A high level language is a programming language that allows code to be written.
- It is similar to a natural human language, such as Welsh or English.
- High level languages are used when the execution speed is not critical, e.g. in common productivity applications, such as a word processor.
- Examples
- Basic
- Java
- Pascal
- Cobol
- C#
- C++
Machine code
- Machine code is the opposite of a high level language in that it does not resemble any natural language and is made up entirely of bit patterns (instructions or data) that can be executed directly by the CPU.
- High level languages have to be converted into machine code before they can be executed by the CPU.
Variables
- In computer programming, a variable may be required to store data that can change.
- Variables are given identifiers (names) that should reflect the data being stored in them.
- Dynamic
- Each time a dynamic variable is defined, it is assigned a new location in memory and has a lifespan that ends when the sub procedure in which it was defined ends.
- For example, if within a sub procedure you assign the number 2.14 to a dynamic variable (and do not change it) and the sub procedure ends, the next time you run that sub procedure the dynamic variable will no longer contain any value.
- Each time a dynamic variable is defined, it is assigned a new location in memory and has a lifespan that ends when the sub procedure in which it was defined ends.
- Static
- Each time a program is run, static variables are stored in a location in memory and have a lifespan that lasts the entire time that program is running.
- For example, if you assign the number 2.14 to a static variable (and do not change it), the static variable will still contain 2.14 the next time you run the sub procedure and until the whole program stops running.
- Each time a program is run, static variables are stored in a location in memory and have a lifespan that lasts the entire time that program is running.
- Local
- A local variable is a variable that is defined within a sub procedure and as such is only accessible from within that same sub procedure. This is known as its scope.
- Global
- A global variable is a variable that has a larger scope as it is defined globally and is therefore accessible from anywhere within a program. The advantage of defining a local variable over a global variable is that it is easier to track the changes to a variable and the reason for the changes when it is only used within a sub procedure.
- An advantage of defining a global variable over a local variable is that sometimes it can be the most efficient way of ensuring that an important piece of data is accessible to all sub procedures, e.g. the details of the user currently logged into a program.
Constants
- Constants are used in computer programming to store data that does not change.
- Constants are also given self-documenting identifiers that should reflect the data being stored in them.
Informationen
- Beschreibung
- banter banter Mindmap am Programming, erstellt von isaac.murray.jon am 10/05/2016.
- Erstellt von
- isaac.murray.jon
- Aufrufe
- 0
- Bewertung