A190017 Inverse permutation to A190016: lexicographical ordering of integers 1 .. 10^4.
1, 1113, 2224, 3335, 4446, 5557, 6668, 7779, 8890, 2, 114, 225, 336, 447, 558, 669, 780, 891, 1002, 1114, 1225, 1336, 1447, 1558, 1669, 1780, 1891, 2002, 2113, 2225, 2336, 2447, 2558, 2669, 2780, 2891, 3002, 3113, 3224, 3336, 3447, 3558, 3669, 3780, 3891
Offset: 1
Links
- Reinhard Zumkeller, Table of n, a(n) for n = 1..10000 (full sequence)
Crossrefs
Programs
-
Haskell
import Data.List (elemIndex) import Data.Maybe (fromJust) a190017 n = a190017_list !! (n-1) a190017_list = map (succ . fromJust . (`elemIndex` a190016_list)) [1..10000]
-
PARI
A190017=vecsort(A190016=vecsort(vector(10^4,n,Str(n)),,1),,1) \\ M. F. Hasler, Oct 26 2019
Comments