https://github.com/arkantrust/kaprekar_constant
Kaprekar's constant implementation on python.
https://github.com/arkantrust/kaprekar_constant
Last synced: 10 months ago
JSON representation
Kaprekar's constant implementation on python.
- Host: GitHub
- URL: https://github.com/arkantrust/kaprekar_constant
- Owner: arkantrust
- Created: 2023-04-15T06:10:52.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2023-09-03T02:32:14.000Z (almost 3 years ago)
- Last Synced: 2025-07-06T08:03:59.945Z (12 months ago)
- Language: Python
- Size: 4.88 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Kaprekar's constant - 6174
For any 4-digit number with at least 2 different digits:
1. if arranged in descending and ascending order,
2. subtracted the smaller number from the bigger one,
3. Kaprekar's constant (6174) will be returned
4. (many iterations may be needed).
## Objective
1. I like mathematics, it's just for fun lol
2. It's been practical to learn how to make GUI's
## See also
- [Kaprekar's Constant](https://en.wikipedia.org/wiki/6174#:~:text=The%20number%206174%20is%20known,(leading%20zeros%20are%20allowed).)
- [Algorithm](https://en.wikipedia.org/wiki/Kaprekar%27s_routine)