A107322 English name for number and its reverse have the same number of letters.
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 14, 22, 33, 34, 35, 38, 41, 43, 44, 45, 48, 53, 54, 55, 58, 66, 67, 69, 76, 77, 79, 83, 84, 85, 88, 96, 97, 99, 101, 102, 103, 104, 105, 106, 107, 108, 109, 111, 112, 113, 115, 118, 121, 122, 123, 124, 125, 126, 127, 128, 129, 131, 132
Offset: 0
Examples
35 is in sequence because 35 ("thirty-five") and 53 ("fifty-three") each have 10 letters in English (dashes not counted).
Links
- Michael S. Branicky, Table of n, a(n) for n = 0..10000
Programs
-
Mathematica
Select[Range[0,132],Length[Select[Characters[IntegerName[#,"Words"]],LetterQ]]==Length[Select[Characters[IntegerName[FromDigits[Reverse[IntegerDigits[#]]],"Words"]],LetterQ]]&] (* James C. McMahon, Feb 12 2024 *)
-
Python
from num2words import num2words def n2w(n): map = {ord(c): None for c in "-, "} return num2words(n).replace(" and", "").translate(map) def ok(n): return len(n2w(n)) == len(n2w(int(str(n)[::-1]))) print([k for k in range(133) if ok(k)]) # Michael S. Branicky, Feb 12 2024
Extensions
10 inserted by James C. McMahon, Feb 12 2024
Comments