Skip to content

maths: add Kaprekar number implementation#14562

Open
Eraol wants to merge 1 commit intoTheAlgorithms:masterfrom
Eraol:add-kaprekar-number
Open

maths: add Kaprekar number implementation#14562
Eraol wants to merge 1 commit intoTheAlgorithms:masterfrom
Eraol:add-kaprekar-number

Conversation

@Eraol
Copy link
Copy Markdown

@Eraol Eraol commented Apr 18, 2026

Describe your change:

  • Add an algorithm :
    Add implementation of Kaprekar numbers in maths/special_numbers/kaprekar_number.py.
    A Kaprekar number is a number whose square can be split into two parts that add up to the original number (e.g. 45² = 2025
    → 20 + 25 = 45).

Checklist:

  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized.
  • I know that pull requests will not be merged if they fail the automated tests.
  • This PR only changes one algorithm file. To ease review, please open separate PRs for separate algorithms.
  • All new Python files are placed inside an existing directory.
  • All filenames are in all lowercase characters with no spaces or dashes.
  • All functions and variable names follow Python naming conventions.
  • All function parameters and return values are annotated with Python type hints.
  • All functions have doctests that pass the automated testing.
  • All new algorithms include at least one URL that points to Wikipedia or another similar explanation.

@algorithms-keeper algorithms-keeper bot added the awaiting reviews This PR is ready to be reviewed label Apr 18, 2026
@Raheel-glicth
Copy link
Copy Markdown

can you assign me this work?
@Eraol

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting reviews This PR is ready to be reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants