Skip to content
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 killer-sudoku-helper exercise #787

Merged
merged 1 commit into from
Jan 21, 2025
Merged

Conversation

ErikSchierboom
Copy link
Member

No description provided.

Copy link
Member

@tasxatzial tasxatzial left a comment

Choose a reason for hiding this comment

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

Just by looking at the description and your solution, i would bump the difficulty to 5 or 6.

Prerequisites: conditionals, vectors or lists (or both), maybe numbers.

Function parameters: All 3 parameters are cage parameters. The general guideline in Clojure is to provide them as a map. So the input would look like {:sum 5 :size 1 :exclude []}. This will also allow practicing map destructuring.

@ErikSchierboom
Copy link
Member Author

Updated!

Copy link
Member

@tasxatzial tasxatzial left a comment

Choose a reason for hiding this comment

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

To keep it simple for future exercises, please disregard what i said here about maps as general guideline. Let's just say we picked maps because it matches the canonical-data and it was a good opportunity for practicing maps. Another good option here would be to use a multi-arity function, with the exclude parameter being optional.

@ErikSchierboom
Copy link
Member Author

Let's keep multi arity functions in mind to find an opportunity to use them!

@ErikSchierboom ErikSchierboom merged commit d763db8 into main Jan 21, 2025
2 checks passed
@ErikSchierboom ErikSchierboom deleted the killer-sudoku-helper branch January 21, 2025 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants