-
Notifications
You must be signed in to change notification settings - Fork 10
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
Dice variables #133
Dice variables #133
Conversation
…to dice-variables
…to dice-variables
This PR would end this issue finally: #66 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pleasantly surprised - that was far less difficult to read than I thought it would be. The State monad is doing really wonderful work in simplifying things here. I've added a bunch of comments (most wrt renaming let to var) and found a bug in the stats that needs fixing, but otherwise it seems to work well. Nicely done.
- set (integer, integer, list) - set the item at the index of the first integer to the value of the second integer in the given list | ||
- insert (integer, integer, list) - insert the item at the index of the first integer to the value of the second integer in the given list |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please mention that these are 0-indexed.
dread it
run from it
dice variables are here
including a multitude of changes to the monad stack for dice rolling, parsing dice as a whole, if statements, and let statements (which allow storing of variables as well as lazy evaluation of variables to simulate functions)