Skip to content

Commit

Permalink
improve formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
vladak committed Mar 24, 2024
1 parent 3fac5fc commit 8ab675d
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions modules/for-loop.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ while (<predicate>) {
}
```

Using the for loop is very often easier and more readable.
Using the `for` loop is very often easier and more readable.

Example:
```C
Expand All @@ -42,13 +42,15 @@ for (int i = 0; i < 10; ++i) {
(i.e. it jumps **at** the enclosing `}`) but the `<update>` part is executed.
The execution then continues with the `<predicate>` test. Example:

```
```C
for (int i = 0; i < 3; ++i) {
printf("%d\n", i);
continue;
putchar('a');
}
```
actual output:
```
$ ./a.out
0
1
Expand Down

0 comments on commit 8ab675d

Please sign in to comment.