Skip to content

Add welcome-to-tech-palace exercise #1680

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 33 commits into from
Sep 24, 2021
Merged

Add welcome-to-tech-palace exercise #1680

merged 33 commits into from
Sep 24, 2021

Conversation

ErikSchierboom
Copy link
Member

@ErikSchierboom ErikSchierboom commented Sep 22, 2021

Closes #1613

@junedev I haven't gotten around to adding the tests, but I can do that later. Could you review this PR?

@ErikSchierboom ErikSchierboom force-pushed the strings-exercise branch 2 times, most recently from 8818996 to 8ca735e Compare September 23, 2021 10:16
@ErikSchierboom ErikSchierboom marked this pull request as ready for review September 23, 2021 10:39
@ErikSchierboom
Copy link
Member Author

@junedev @ekingery This is ready for review. I don't know Go, so please check for any stupid mistakes :)

@jmrunkle jmrunkle added status/awaiting-maintainer This pull request is waiting on one or more maintainers. september-sprint labels Sep 23, 2021
@@ -0,0 +1,37 @@
# About

A `string` in Go is an immutable sequence of bytes, which don't necessarily have to represent characters.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not certain if we want to specifically mention runes here. Perhaps not because you added another concept for runes that is supposed to be taught by logs-logs-logs.

Any preference @ekingery?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, as long as it is covered elsewhere, let's leave them out. In addition to the go101 link you recommend for the links.json below, I would defer to @ErikSchierboom as to whether this link is also appropriate: https://go.dev/blog/strings

It is much more comprehensive and does cover runes, which might be nice if people want to take a deeper dive with this concept.

Copy link
Contributor

@ekingery ekingery left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great overall! I chimed in on a couple of comments, but didn't scrutinize the whole PR.

@@ -0,0 +1,37 @@
# About

A `string` in Go is an immutable sequence of bytes, which don't necessarily have to represent characters.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, as long as it is covered elsewhere, let's leave them out. In addition to the go101 link you recommend for the links.json below, I would defer to @ErikSchierboom as to whether this link is also appropriate: https://go.dev/blog/strings

It is much more comprehensive and does cover runes, which might be nice if people want to take a deeper dive with this concept.

import "strings"

strings.ToLower("TEST") // Output: "test"
```
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ErikSchierboom Without a list of more functions or a link to where to find more functions, the info in the introduction is currently not sufficient to solve the exercise.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I disagree with this statement for the following reason. One of the core ideas of Concept Exercises was to have students figure things out by themselves as much as possible. The way I intended this to work is to provide just enough context to allow the student to Google things by themselves, but to always provide the hints as a fallback should the student not manage to figure things out. Applying that to this example, we've explained that there is a strings package (letting the student learn its exact name, useful for Googling), shown how to import it and how to use one example function (purposefully not one of the functions the student requires).

I know not everyone is comfortable with the above approach, but it is the original idea for how to introduce concepts in Concept Exercises. If you as Go maintainers would prefer to use a different approach, I'm okay with that, but I think there's great value in the above approach.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am ok either way, I was just a little confused because I had the feeling you were pushing a lot for providing all the needed info in other exercises. I got the wrong impression from that. Just ignore the comment.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No problem. I will get this wrong from time to time too, so 🤷

@junedev junedev added status/awaiting-contributor This pull request is waiting on the contributor. and removed status/awaiting-maintainer This pull request is waiting on one or more maintainers. labels Sep 23, 2021
@junedev
Copy link
Member

junedev commented Sep 24, 2021

@ErikSchierboom Not sure whether this should be part of this PR or not but at some point we need to go through all exercises that currently have "string-formatting" as prerequisite and check whether they need that one or the new "strings". If you dont want to include this here maybe create a ticket so we dont forget about it.

@ErikSchierboom
Copy link
Member Author

@junedev Excellent point. I added this commit: f38828e

@junedev
Copy link
Member

junedev commented Sep 24, 2021

@junedev Excellent point. I added this commit: f38828e

Thanks! Looks correct to me.

@ErikSchierboom
Copy link
Member Author

I'm merging this. Thanks all!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
x:size/large Large amount of work
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Sept Sprint] New Exercise for Strings
6 participants