-
-
Notifications
You must be signed in to change notification settings - Fork 110
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
Add Custom types concept and associated exercise #368
Conversation
While reading this I realized that this concept does not talk at all about type variables. So I've re-read the previous exercises about list and records and they also do not talk about type variables. I think it could make sense curriculum-wise but especially in Small digression about the
|
|
I think it is probably good to mention type variables here, I think the dependency tree might start to get super tangled otherwise. And Maybe is a custom type, so it's strange to make it a pre requisite. Having this and then another concept for "custom types with type variables" could make sense though. If we add type variables to this concept / exercise, maybe we can change the approval type
This might also be an opportunity to introduce a requirement for the student to create a more complicated type. For example if |
This probably makes sense anyway, so I've added it. I made the commit in the 'records-concept' branch by mistake though. I can cherry pick it here if you want. |
I think that is all the comments addressed, although obviously there is still some discussion to do! Let me know what you think! Cheers, Cedd |
Well we learn to count before learning that Z together with addition forms a group where 0 is the identity element. Maaaybe the comparison is a little stretched but that's to say that people learn well by example and then generalization. So it would not be too strange to me to first learn about
Right, forget what I said ...
I don't have a good feeling on this one. It's not super valuable. Let's leave generics and advanced type variables for later.
Yep that's fine |
Its much simpler and more concise than the elm programming one
Rebased on main to fix configlet. |
This made me chuckle :) |
No description provided.