Term 3 Binary and Python Flashcards

1
Q

How many values does binary have?

A

2

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

What number does 0 0 0 1 0 1 0 1 represent in 8 bit binary?

A

21

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

What number does 0 0 0 1 0 1 0 0 represent in 8 bit binary?

A

20

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

What number does 0 0 0 1 0 0 1 1 represent in 8 bit binary?

A

19

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

How would the number 33 be represented in 8 bit binary?

A

0 0 1 0 0 0 0 1

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

How would the number 99 be represented in 8 bit binary?

A

0 1 1 0 0 0 1 1

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

What is pseudocode?

A

A method of writing up a set of instructions for a computer program using plain English. This is a good way of planning a program before coding.

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

What is a program?

A

A sequence of instructions for a computer.

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

What is a programming language?

A

A language used by a programmer to write a piece of software e.g. Python

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

What is programming?

A

The process of writing computer software.

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

What word means “the set of rules that define the combinations of symbols that are considered to be correctly structured programs in that language”?

A

Syntax

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

What would happen if you wrote the following program using python:

print (“Hello, World)

A

An error message would be displayed as a quote mark is missing

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

Which word best fits this description “In a computer program, this is a memory location where values are stored.”?

A

Variable

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

What would happen if you wrote the following program using python:

print (“2” + “2”)

A

22 would be displayed on the screen (the values shown are strings not integer values so + puts the two together and doesn’t add them up)

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

Which data type represents numbers containing a decimal point?

A

Float

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

Which data type represents whole numbers?

A

Integer

17
Q

Which data type represents a list of characters in order eg. “Hello World”?

A

String

18
Q

What would happen if you wrote the following code using Python:

print(“What is your name?”)

name = input()

print(“Hello “ + name)

A

The user would be asked their name, if they then input their name as Dave this would then be printed as “Hello Dave” on the screen