1
Q

What is the name of the internal representation of literals used by an executed python program?

A

Objects OR Values

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

What are operators and operands?

A

Operators are functions that complete acts of computations.

Operands are the objects that are worked on by operators

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

What is a function call?

A

This is when we invoke a function in the form X(x)

X = name of function
x = inputs
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the name of the output of a function?

A

Output OR Return Value

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

What do pearentheses do?

A

They invoke functions.

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

Are functions objects?

A

YES

Invoked by ()

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

Are functions objects?

A

YES

Invoked by ()

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

Can you concatenate a string and integer?

A

Yes, only if you first convert the integer into a string.

Otherwise, no.

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

Can you concatenate a string and integer?

A

Yes, only if you first convert the integer into a string.

Otherwise, no.

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

What are the main data types?

A
Int = integers
Floats = decimals
Str = strings
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is a variable?

A

A variable just refers to an object/value

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

What are assignment statements?

A

These are statements using ‘=’ to attach one object to another thus creating new variables.

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

Can variables contain spaces?

A

NO

use underscores if needed

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

Are variables case sensitive?

A

YES

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

Can variables start with a number?

A

NO

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

Can variables contain characters other than letters and numbers?

A

NO (for the most part)

16
Q

Why is “class” an illegal name for a variable in python?

A

This is a python keyword

17
Q

What is a statement?

A

It is an instruction that the python interpreter can execute

18
Q

What is an expression?

A

This is a combination of literals, variable names, operators and calls to functions

19
Q

What is the term which refers to when python interpreters checks prior to execution?

A

Evaluation

20
Q

What determines the order of evaluation of an expression?

A

The rules of precedence.

21
Q

What are the rules of precedence?

A
  1. (Parentheses) have highest precedence
  2. Exponentiation
  3. Multiplication and Division, then Addition and subtraction
  4. Operators with same precedence read from left to right
22
Q

Is it possible to reassign a variable?

A

YES

23
Q

What is the term for when a variable first evaluated?

A

Initialisation