Skip to content

Commit 5880581

Browse files
committed
Apply suggestions from code review
Two final nits...
1 parent c635460 commit 5880581

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

exercises/practice/rotational-cipher/.approaches/ascii-values/content.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ And if the new number is over 26 we want to make sure that it "wraps around" to
4747
To properly use modulo for a range we have to make sure that it starts at zero, so we subtract 65.
4848
To get back to a letter in the ascii range we add 65 and use the [`chr`][chr] method to convert the value to a letter.
4949

50-
The process is the same for a lowercase letter, but with 97 subtracted to put the letter in the lowercase ascii range of 97 - 123.
50+
The process is the same for a lowercase letter, but with 97 subtracted/added to put the letter in the lowercase ascii range of 97 - 123.
5151

5252
Any element that is not a letter (_whitespace or punctuation_) is added directly to the result string.
5353
When all the elements have been looped over, the full result is returned.

exercises/practice/rotational-cipher/.approaches/str-translate/content.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ To create a translation table, `str.makestrans` is used.
2828
For our solution, the first argument is the `AlPHABET` constant + the `AlPHABET` constant in uppercase.
2929
The second argument is the `translator` variable + uppercase `translator` variable.
3030

31-
`makestrans` does is that it takes the [Unicode][unicode] values of the first argument and maps them to the corresponding Unicode values in the second argument, creating a `dict`.
31+
`str.makestrans` takes the [Unicode][unicode] values of the first argument and maps them to the corresponding Unicode values in the second argument, creating a `dict`.
3232

3333
```python
3434
>>> str.maketrans("abc", "def")

0 commit comments

Comments
 (0)