Skip to content
This repository has been archived by the owner on Jul 18, 2020. It is now read-only.

Fixes and improvements to the Racket code #4

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Fixes and improvements to the Racket code #4

wants to merge 7 commits into from

Conversation

elibarzilay
Copy link

I've fixed some bugs and made some improvements, but I tried to do so while keeping it close to the original.

(Either by calling Racket on the file, or running it directly.)
`=' can't work on pairs; proper range testing.  This makes it actually
playable...
Since this is the preferred style in Racket code.
There's no point in sending it the input and calling it after showing
the board -- much simpler to do it all in it.
Use `rand-pos' to abstract over postion making, and use a loop instead
of folding over an ignored list.
In general, we try to avoid generic values like lists (as used in
Scheme/Lisp) and hashes (as used in JS/Ruby/etc) when we have a specific
type.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant