add: 回文数
This commit is contained in:
1 parent
da0e4f1359
commit
304866ecbf
3 files changed
+30
No files matched your search
@@ -0,0 +1,9 @@
|
||||
import { isPalindrome } from '../../src/math/palindrome-number'
|
||||
|
||||
test('回文数', () => {
|
||||
expect(isPalindrome(121)).toBe(true)
|
||||
expect(isPalindrome(0)).toBe(true)
|
||||
expect(isPalindrome(11)).toBe(true)
|
||||
expect(isPalindrome(10)).toBe(false)
|
||||
expect(isPalindrome(-121)).toBe(false)
|
||||
})
|
||||
Reference in new issue
Block a user