add: 快乐数

This commit is contained in:
2020-04-30 13:58:03 +08:00
parent de9ff35202
commit ecab5b8850
3 changed files with 25 additions and 0 deletions

View File

@ -0,0 +1,6 @@
import { isHappy } from '../../src/array/happy-number'
test('快乐数', () => {
expect(isHappy(19)).toBe(true)
expect(isHappy(5)).toBe(false)
})