diff --git a/05.Loops.md b/05.Loops.md index 0fc1e39..b254af8 100644 --- a/05.Loops.md +++ b/05.Loops.md @@ -242,7 +242,7 @@ The `else` clause is executed after the loop completes its execution without hit # Example of else with a for loop for number in range(3): print(number) - if number >= 2: + if number > 2: print('123213') break else: @@ -439,7 +439,7 @@ for i in range(1, 4): You can use [`Python Visualizer`](https://pythontutor.com/visualize.html#mode=edit) in order to understand the concept of `nested loops` better. -There are lots of practical cases where software engenieer can use nested loops. You will notice, that we sometimes coming back to them working with advanced data structures. +There are lots of practical cases where software engenieer can use nested loops. You will notice that we sometimes will be coming back to them working with advanced data structures. ### 3.1 Assigments @@ -579,7 +579,7 @@ D) The else part is not valid for loops ### Task 1: The Guessing Game -**Objective:**: Write a program that selects a random number and asks the user to guess it. Use a while loop to allow multiple attempts until they guess correctly or choose to exit. +**Objective:** Write a program that selects a random number and asks the user to guess it. Use a while loop to allow multiple attempts until they guess correctly or choose to exit. ``` @@ -594,7 +594,7 @@ The correct number was 7. Better luck next time! ### Task 2: Nested loops -**Objective:**: Write a program using nested loops to match the following output. +**Objective:** Write a program using nested loops to match the following output. ```python Output: @@ -608,7 +608,7 @@ Output: ### Task 3: The Factorial Calculator -**Objective:**: Create a program that computes the factorial of a given number using a `for` loop. +**Objective:** Create a program that computes the factorial of a given number using a `for` loop. ``` Input: