Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove extra spaces from 05-loop.md #1078

Merged
merged 1 commit into from
Apr 18, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions episodes/05-loop.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ print(odds[3])
This is a bad approach for three reasons:

1. **Not scalable**. Imagine you need to print a list that has hundreds
of elements. It might be easier to type them in manually.
of elements. It might be easier to type them in manually.

2. **Difficult to maintain**. If we want to decorate each printed element with an
asterisk or any other character, we would have to change four lines of code. While
Expand Down Expand Up @@ -159,7 +159,7 @@ of the loop body (e.g. `end for`); everything indented after the `for` statement

In the example above, the loop variable was given the name `num` as a mnemonic;
it is short for 'number'.
We can choose any name we want for variables. We might just as easily have chosen the name
We can choose any name we want for variables. We might just as easily have chosen the name
`banana` for the loop variable, as long as we use the same name when we invoke the variable inside
the loop:

Expand Down
Loading