OFFSET
1,2
COMMENTS
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..10000 (full sequence)
Eric Weisstein, LexicographicOrder
Wikipedia, Lexicographical order
EXAMPLE
a(13) = 1008;
a(14) = 1009;
a(15) = 101;
a(16) = 1010;
a(17) = 1011;
largest term a(5) = 10000;
last term a(10000) = 9999, largest term lexicographically.
PROG
(Haskell)
import Data.Ord (comparing)
import Data.List (sortBy)
a190016 n = a190016_list !! (n-1)
a190016_list = sortBy (comparing show) [1..10000]
(PARI) eval(Set(vector(10^4, n, Str(n))) \\ M. F. Hasler, Oct 25 2019
CROSSREFS
KEYWORD
nonn,base,fini,full
AUTHOR
Reinhard Zumkeller, May 06 2011
STATUS
editing