guide.md: update Q&A in "Dictionaries Challenges" section#335
Merged
wrightaprilm merged 2 commits intodatacarpentry:gh-pagesfrom Nov 29, 2018
Merged
guide.md: update Q&A in "Dictionaries Challenges" section#335wrightaprilm merged 2 commits intodatacarpentry:gh-pagesfrom
wrightaprilm merged 2 commits intodatacarpentry:gh-pagesfrom
Conversation
Updated question and answer in section **Dictionaries Challenges** based on corresponding section in episode [01-short-introduction-to-Python.md](https://github.com/datacarpentry/python-ecology-lesson/blob/gh-pages/_episodes/01-short-introduction-to-Python.md)
NPalopoli
added a commit
to NPalopoli/python-ecology-lesson
that referenced
this pull request
Nov 21, 2018
Refers to datacarpentry#335 - `dict` values should never be referred to by position, but by key.
Contributor
Author
|
Nice one! Thanks Maxim and April. I've created #336 to address this in the
lesson.
…--
Nicolás Palopoli
Structural Bioinformatics Group
Universidad Nacional de Quilmes - CONICET
http://orcid.org/0000-0001-7925-6436
On Wed, Nov 21, 2018 at 6:47 PM April Wright ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In _extras/guide.md
<#335 (comment)>
:
> @@ -40,12 +40,19 @@ installation. Otherwise, it will tell you that the system is good to go and read
`tuple`
### Dictionaries Challenges
-* Can you do reassignment in a dictionary? Give it a try.
+
+* Changing dictionaries: 2. Reassign the second value.
Good catch - easy to forget. I like
"Reassign the value that corresponds to the key "2"."
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#335 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABonERHFjEWjwwMPPuslvycq2ZgsNByoks5uxZGVgaJpZM4YtdtY>
.
|
Contributor
Author
|
I agree, thanks! And I think we can avoid the double quotes without
allowing for confusions.
I'm not sure if the previous changes have been accepted or not yet. Please
go ahead with the PR for removing the double quotes and close the issue if
done.
…On Wed, Nov 21, 2018 at 7:01 PM Maxim Belkin ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In _extras/guide.md
<#335 (comment)>
:
> @@ -40,12 +40,19 @@ installation. Otherwise, it will tell you that the system is good to go and read
`tuple`
### Dictionaries Challenges
-* Can you do reassignment in a dictionary? Give it a try.
+
+* Changing dictionaries: 2. Reassign the second value.
Please don't hate my but... no double quotes around 2 because 2 and "2"
are two different and legitimate keys.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#335 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABonEXmkZ5Krr6-jY17j8xGzlB1fO9q8ks5uxZTrgaJpZM4YtdtY>
.
|
wrightaprilm
suggested changes
Nov 27, 2018
Changed reference to "the second value" of dictionary to "the value that corresponds to the key `2`."
wrightaprilm
approved these changes
Nov 29, 2018
Contributor
|
Great, thanks for fixing that. I'm happy if you're happy, @maxim-belkin. |
maxim-belkin
approved these changes
Nov 29, 2018
Contributor
|
Thanks @NPalopoli! |
zkamvar
pushed a commit
that referenced
this pull request
May 8, 2023
Refers to #335 - `dict` values should never be referred to by position, but by key.
zkamvar
pushed a commit
that referenced
this pull request
May 8, 2023
guide.md: update Q&A in "Dictionaries Challenges" section
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Updated question and answer in section Dictionaries Challenges based on corresponding section in episode 01-short-introduction-to-Python.md