Chapter 3 - Selection Flashcards

1
Q

What are three basic ways of controlling the order in which the program are carried out?

A
  • sequence
  • selection
  • iteration
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What does a selection statement start with ?

A

if

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

What is a method?

A

is written using dot notation with the name of the object followed by a full stop then the name.

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

What is a function?

A

is a written function with the function name followed by the name of the object in parentheses.
- for example: numchars = len(astring)

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

What is elif?

A

else if

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