Skip to content

Conversation

@agarwalpranay02
Copy link
Owner

Describe your change

  • Add an algorithm

Added an iterative implementation to compute sum of decimal digits at maths/add_digits.py.
Includes doctest examples and input validation. Beginner-friendly contribution for Hacktoberfest.

Checklist

  • I have read CONTRIBUTING.md
  • This pull request is all my own work and I have not plagiarized.
  • I know this PR will not be merged if it fails the automated tests.
  • This PR only changes one algorithm file.
  • All new Python files are placed inside an existing directory.
  • All filenames are in all lowercase with no spaces or dashes.
  • All functions and variable names follow Python naming conventions.
  • All function parameters and return values are annotated with type hints.
  • All functions have docstrings and pass automated testing.
  • Includes at least one URL reference to explanation.

Reference: https://en.wikipedia.org/wiki/Digital_root

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