This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * What's a happy number? https://en.wikipedia.org/wiki/Happy_number | |
| * | |
| * Simple brute force solution that just evaluates if the happy number sequence reaches one within [MAX_DEPTH] iterations. | |
| */ | |
| object HappyNumbers { | |
| const val MAX_DEPTH = 10_000 | |
| @JvmStatic |
OlderNewer