Karteikarten
Variables, constants and data types
Karten in diesem Stapel (12)
- 1What is a variable?A value that can change when the program is running
Given by an meaningful identifier
e.g. surname or length - 2Why should the identifier always be written in the same way?Some computer languages are case sensitive
- 3What should join the spaces if the identifier consists of two words?An underscore
e.g. first_name, tutor_group - 4Where should variables be declared?At the start of a program
- 5What does the input command do?Takes user input and assigns it to a variable
- 6What is a constant?A value that cannot change when the program is running
They are also given identifiers - 7What are data types?When variables and constants are declared they may have to be defined as holding data of a particular type
- 8What is a string?A series of characters that can be manipulated as a group
e.g. name = "David" - 9What is a character?A single character
e.g. initial = "W" - 10What is an integer?A whole number
e.g. age = 15 - 11What is a real?Numbers including a decimal point
e.g. length = 13.69 - 12What is a boolean?Having one or two possible values, usually true or false
Informationen
- Beschreibung
- GCSE Computing (7 Programming) Karteikarten am Variables, constants and data types, erstellt von Anisha Rai am 20/04/2016.
- Erstellt von
- Anisha Rai
- Aufrufe
- 4
- Tags
- Bewertung