Skip to content

luhn: non-digit at end is invalid #1420

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

Merged
merged 1 commit into from
Dec 22, 2018
Merged

Conversation

bitfield
Copy link
Contributor

From luhn: add test case with non-digit at the end:

Problem: I had a student only include the digits before the first invalid character. There was no test that failed his solution.

Solution: Added a test that should return false but does not if the student takes only the numbers up to first non-digit.

@rpottsoh
Copy link
Member

Let me know if you need me to merge.

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