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

Dominoes: Add test case #2151

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions exercises/dominoes/canonical-data.json
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,20 @@
"dominoes": [[1, 2], [2, 3], [3, 1], [4, 5], [5, 6], [6, 4]]
},
"expected": false
},
{
"uuid": "709f7b9e-239d-4e20-b4a1-61f46257a647",
"description": "can't try forever",
"comments": [
"Some solutions try to build a chain and backtrack when none is found",
"but can end up in infinite loops, when not properly taken care of.",
"This ensures that such cases are identified."
],
"property": "canChain",
"input": {
"dominoes": [[1, 2], [2, 4], [4, 2], [4, 3]]
},
"expected": false
}
]
}