<a id="ch-15"></a>

## Chapter 15 — A changed impact is not this print

### Learning outcomes

After this chapter, you should be able to:

1. Read F4's impact from the tuple that was actually sorted.
2. Compute the product if that impact were 3.
3. Refuse to replace the embedded print with the hypothetical.

### 15.1 Impact 2 is what `sorted` saw. Impact 3 is a different key.

The stored F4 tuple ends in `2, 2`. Likelihood 2 times impact 2 is 4. The key is `(-4, "F4")`, which sits between the sixes and F2. The third printed line is that result: `F4 score=4 medium`.

If the last integer were 3, the product would be 6 and the key would be `(-6, "F4")`. Three keys would then start with `-6`, and the id strings would order them F1, F3, F4, with F2 still last on product 2. That order is a calculation about a tuple this file does not hold. Pasting it under the lab's output fence would report a run that did not happen.

| | Impact stored | Product | Place in the embedded print |
|---|---:|---:|---|
| F4 as written | 2 | 4 | Third line |
| F4 with the last integer replaced by 3 | 3 | 6 | Not a line in this file |

### 15.2 Worked example

| Offered page | Matches the file? | Decision |
|---|---|---|
| F4 on the third line at score 4 | Yes | Keep |
| "F4 now ties the sixes, so quote that as the lab." | The file was not edited | Refuse |
| "Delete F4 from the list so the tie goes away." | The tuple stays | Refuse |

> **Synthetic case.** One ranking print. The alternate impact stays in the notebook.

### Errors and limits

Do not overwrite the embedded F4 line with the alternate product.

### Apply

- **EX061 — Unprinted change.** What does this file print for F4, and where would F4 sit if its impact were 3? *Rubric:* 3 = the file prints score 4 in third place; impact 3 would make product 6 and the id order would be F1, F3, F4, then F2; that order is not the embedded print;; 2 = score 4 is the print and the alternate is not;; 1 = one score;; 0 = none.

<!-- open-cyber-academy:chapter-navigation:start ch-15 -->
### Continue studying — lesson 15 (chapter 15 of 20)

[← Chapter 14](#ch-14) · [Course chapter index](../SUBJECTS.md) · [Chapter 16 →](#ch-16)

Continue to the next authored lesson.
<!-- open-cyber-academy:chapter-navigation:end -->

## Worked answers

<a id="answer-ex061"></a>
**EX061.** The file prints F4 at score 4 in third place. Impact 3 would make product 6, and the id order would be F1, F3, F4, then F2. That order is not the embedded print.
