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

armstrong-numbers: Include excluded tests #712

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

Conversation

tasxatzial
Copy link
Member

Added the final two tests involving big integers. Without these tests, some solutions improperly relied on Java interop for exponentiation, which is incorrect since Java's exponentiation functions return floating-point numbers instead of integers, as required here. Additionally, without these tests, incorrect solutions using Java interop could pass all tests. This PR addresses both issues.

Also

  • Updated the armstrong_numbers.clj starter file with a proper function template
  • Explicitly check with true? and false? as true and false are the exact values expected to be returned by armstrong?
  • Updated example solution to pass the new tests

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.

1 participant