Corrections - Tom
Compare changes
- Tom Reclik authored
+ 1
− 1
```
```
```
```
```
If we want to run the code a certain number of times, we can use the ```range(start, stop, step)``` function, where ```start``` specifies the number we want to start from, ```stop``` the final number (excluding this value) and ```step``` the step size. The step size is optional and assumed to be 1 if we do not specify it.
```
```
```
```
```
```
For example, in the code below we first increase i, then do the check and then print the value, whereas above we first printed the value and then increased it by 1. We observe that, indeed, the value 2 is not printed, but the loop now runs between 1,...,11 instead of 0,...,10. However, if we were to place the statements in other orders, we would find that either there is not effect (the execution skips over everything after ```continue```) or we have an infinite loop, ...
```
```
```