selections Flashcards

1
Q

two foundations of software engineering

A

first write pseudocode/flowchart; then write actual code

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

flowchart style

A
  • start/end are ellipses
  • input/output are trapezoids
  • operations are rectangles
  • selections are diamonds
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

selection

A

basically and if statement or related code

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

XOR operator

A
  • ^ symbol

- returns true when only one boolean is true

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

AND operator

A
  • && is symbol

- returns true if both booleans are true

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

OR operator

A
  • || symbol

- returns true when at least one boolean is true

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

else statement

A

excuted only when boolean is false. owned by whichever if bracket is closest

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

else if statement

A

similar to else but has an additional boolean that has to be true to execute

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

printf

A

-print FORMATTED

%(JUSTIFIED)(SPACES).(PRECISION){data_type}
text will be right justified. \n for new line. minus sign in justified for left

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