Autumn Test Flashcards

1
Q

What is the difference between a parameter and an argument?

A
Parameter = A parameter represents a value that the procedure expects you to pass when you call it.
Argument = An argument represents the value that you pass to a procedure parameter when you call the procedure.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is binary?

A

Base 2 number system which represents on/off or voltage/no voltage

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is a bit?

A

A binary digit, either 1 or 0

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is a byte?

A

A byte is 8 bits

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is hexadecimal or hex?

A

A number system based on 16s

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How do you convert Denary to Hex?

A

Divide denary number by 16 until it can not be divided anymore

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Why is hexadecimal used?

A

Hexadecimal is used to simplify binary number. It easier fro the human brain to remember ACE than 1010 1100 1110
Also it is easier to to convert binary to hexadecimal than decimal to hexadecimal

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is ASCII?

A

ASCII is code that gives each letter of the alphabet a deanery digit so that it can be understood by computers
It can go up to 128 characters
Most computers use ASCII to transfer data from one computer to another

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is a high level language?

A

A coding language that allow the user not to communicate with computers using binary instead the user uses a language which is similar to english

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is an example of a high level language?

A

Python

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is an example of machine code?

A

Binary

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is logic?

A

The study of the principles of reasoning. In computer science those principles relate to how you communicate with computers

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What are the three basic logic structures in all programming languages?

A

Sequence
Selection
Iteration

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is the definition of sequence?

A

Running code top to bottom without skipping anything

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What is the definition of selection?

A

A question is asked which produces a Boolean value (either true or false) and the action that follows depends on the answer

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is the definition of iteration?

A

This means looping or executing the same set of instruction a given number of times or until a specified result is obtained

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What is a variable?

A

A variable points to a memory location containing a value (some data)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What is a constant?

A

Constants are special types of variable whose values stay the same, or only rarely change throughout the program.
If a constant changes it will not be in the normal running of the program but as some sort of configuration

19
Q

What is the definition of an integer?

A

A whole number

20
Q

What is the definition of a string?

A

Any characters including none

21
Q

What is the definition of a boolean value?

A

True or false

22
Q

What is the definition of a float/real?

A

A decimal number

23
Q

What is the definition of Char/single character?

A

A single character, letter, number, punctuation mark

24
Q

Why does a computer need to know what the data type is?

A

Because then the computer knows:
What process can be applied, e.g you can’t divide a string
How much memory space to be put aside, e.g a Boolean only takes up 1 bit of memory, whereas a String will take up much more

25
Q

What is an assignment?

A

Giving a variable a value e.g name=’Harry’

26
Q

What is the definition of a syntax error?

A

When the computer does not understand what is written because the code does not follow the rules of the language.

27
Q

What is the definition of a runtime error?

A

When the syntax is correct but the computer does not understand the instruction.

28
Q

What is the definition of a logic error?

A

When the code runs but the result is not what was expected

29
Q

What is the definition of an algorithm?

A

A sequence of steps taken to solve a problem. The steps use the three basic logic structures; sequence, selection and iteration

30
Q

What is the definition of abstraction?

A

Breaking a problem down into small parts and hiding how the code works

31
Q

In pseudocode what symbol represents less than?

A
32
Q

In pseudocode what symbol represents greater than?

A

>

33
Q

In pseudocode what symbol represents less than or equal to

A
34
Q

In pseudocode what symbol represents greater than or equal to?

A

> =

35
Q

In pseudocode what symbol represents equal to?

A

=

36
Q

In pseudocode what symbol represents not equal to?

A

37
Q

What is the definition of a boolean expression?

A

A expression that produces a boolean value

38
Q

What are the three logic operators?

A

AND
OR
NOT

39
Q

What are the requirements for a AND operator?

A

Both sides of the operator must be TRUE for it to be considered TRUE

40
Q

What are the requirements for a OR operator?

A

Only one or more statement needs to be TRUE for it to be considered TRUE

41
Q

What are the requirements for a NOT operator?

A

NOT turns a TRUE value to a FALSE and a FALSE value to a TRUE

42
Q

What is the definition of validation?

A

Validation is the process of ensuring that the data is sensible not correct

43
Q

What is the definition of an array?

A

A group of data items of the SAME DATA TYPE, which is stored under one identifier (name) in contiguous (one after the other) memory locations
Can be 1 or 2 dimensional

44
Q

What is the difference between a function and a procedure?

A

A function returns a value while a procedure does something but does not return a value