Skip to content

Correct typo#83

Closed
wood-chris wants to merge 1 commit intoLibraryCarpentry:gh-pagesfrom
wood-chris:patch-1
Closed

Correct typo#83
wood-chris wants to merge 1 commit intoLibraryCarpentry:gh-pagesfrom
wood-chris:patch-1

Conversation

@wood-chris
Copy link
Copy Markdown
Contributor

@wood-chris wood-chris commented Mar 29, 2021

-(N-1) is not correct. Given a string, s = 'cow', which has 3 elements:

len(s) => 3
s[-1] => 'w'
s[-3] => 'c' - the first element
s[-(3-1)] => 'o', which is not the first element (but the lesson says it is)

`-(N-1)` is not correct. Given a string, `s = 'cow'`, which has 3 elements:

`len(s)` => 3
`s[-1]` => 'w'
`s[-3]` => 'c' - the first element
`s[-(3-1)]` => 'o', which is not the first element (but the lesson says it is)
@wood-chris
Copy link
Copy Markdown
Contributor Author

Hi @konrad - apparently you might be able to review / approve this and #84?! 🙂 I'm teaching these episodes tomorrow and I'd be keen not to deal with confused participants!

@konrad
Copy link
Copy Markdown
Member

konrad commented Mar 29, 2021

Thanks, @wood-chris. I agree - this is wrong and you fix is correct. I will just get the confirmation of the other maintainer to merge you PR.

@konrad
Copy link
Copy Markdown
Member

konrad commented Mar 29, 2021

This was fixed in #76 which I justed merged. Still, many thanks @wood-chris.

@konrad konrad closed this Mar 29, 2021
chennesy pushed a commit that referenced this pull request Jun 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants