Skip to content

Commit

Permalink
Merge branch 'master' into fix_broken_mute
Browse files Browse the repository at this point in the history
  • Loading branch information
faucomte97 authored Mar 19, 2024
2 parents 163777e + e0acaf4 commit 8a1124f
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 23 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

<!--next-version-placeholder-->

## v5.16.20 (2024-03-13)

### Fix

* Change n to number in levels 106-109 ([#1595](https://github.com/ocadotechnology/rapid-router/issues/1595)) ([`1561bbe`](https://github.com/ocadotechnology/rapid-router/commit/1561bbe57f31a2061049bea504df383e76dfe736))

## v5.16.19 (2024-03-01)

### Fix
Expand Down
2 changes: 1 addition & 1 deletion game/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "5.16.19"
__version__ = "5.16.20"
16 changes: 8 additions & 8 deletions game/messages.py
Original file line number Diff line number Diff line change
Expand Up @@ -2309,12 +2309,12 @@ def description_level106():
def hint_level106():
return (
"""To use a variable to store the number of grid squares the van has to move you can do something like the following:
<pre>n = 1
<pre>number = 1
while not my_van.at_destination():
print n
n += 1</pre>
Variables can be used in place of constants when calling functions. For example to repeat something n times you can do something like the following:
<pre>for count in range(n):</pre>"""
print number
number += 1</pre>
Variables can be used in place of constants when calling functions. For example to repeat something <strong>number</strong> times you can do something like the following:
<pre>for count in range(number):</pre>"""
+ PYTHON_HINT
)

Expand All @@ -2333,7 +2333,7 @@ def description_level107():

def hint_level107():
return (
"To double the value of a variable you can do something like the following:<br><pre>n *= 2</pre>"
"To double the value of a variable you can do something like the following:<br><pre>number *= 2</pre>"
+ PYTHON_HINT
)

Expand All @@ -2350,7 +2350,7 @@ def description_level108():
def hint_level108():
return (
"To decrease the value of a variable by an amount you can do something like the "
"following:<br><pre>n -= 5</pre>" + PYTHON_HINT
"following:<br><pre>number -= 5</pre>" + PYTHON_HINT
)


Expand All @@ -2368,7 +2368,7 @@ def description_level109():

def hint_level109():
return (
"To halve the value of a variable you can do something like the following:<br><pre>n /= 2</pre>"
"To halve the value of a variable you can do something like the following:<br><pre>number /= 2</pre>"
+ PYTHON_HINT
)

Expand Down
28 changes: 14 additions & 14 deletions game/views/level_solutions.py
Original file line number Diff line number Diff line change
Expand Up @@ -241,55 +241,55 @@ def big():
my_van = Van()
n = 1
number = 1
while not my_van.at_destination():
my_van.turn_right()
for count in range(n):
for count in range(number):
my_van.move_forwards()
n = n + 1"""
number = number + 1"""

lvl_107 = """from van import Van
my_van = Van()
n = 1
number = 1
while not my_van.at_destination():
my_van.turn_left()
for count in range(n):
for count in range(number):
my_van.move_forwards()
n = n * 2"""
number = number * 2"""

lvl_108 = """from van import Van
my_van = Van()
n = 6
number = 6
while not my_van.at_destination():
for i in range(n):
for i in range(number):
my_van.move_forwards()
my_van.turn_left()
n = n - 2"""
number = number - 2"""

lvl_109 = """from van import Van
my_van = Van()
n = 0
number = 0
for count in range(4):
my_van.turn_right()
for forward in range(n):
for forward in range(number):
my_van.move_forwards()
n = n + 1
number = number + 1
my_van.turn_right()
while not my_van.at_destination():
for count in range(n):
for count in range(number):
my_van.move_forwards()
my_van.turn_left()
n = n / 2"""
number = number / 2"""

lvl_113 = """from van import Van
Expand Down

0 comments on commit 8a1124f

Please sign in to comment.