This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A319720 #16 Aug 07 2024 10:33:24 %S A319720 0,1,2,3,4,5,9,13,8,9,10,14,12,13,14,15,16,20,36,52,20,21,37,53,36,37, %T A319720 41,57,52,53,57,61,32,36,40,56,36,37,41,57,40,41,42,58,56,57,58,62,48, %U A319720 52,56,60,52,53,57,61,56,57,58,62,60,61,62,63,64,80,144,208,80,84 %N A319720 Write n in 4-ary, sort digits into decreasing order. %H A319720 Seiichi Manyama, <a href="/A319720/b319720.txt">Table of n, a(n) for n = 0..4095</a> %F A319720 n <= a(n) < 4n. - _Charles R Greathouse IV_, Aug 07 2024 %t A319720 Table[FromDigits[ReverseSort[IntegerDigits[n, 4]], 4], {n, 0, 100}] (* _Paolo Xausa_, Aug 07 2024 *) %o A319720 (Ruby) %o A319720 def A(k, n) %o A319720 (0..n).map{|i| i.to_s(k).split('').sort.reverse.join.to_i(k)} %o A319720 end %o A319720 p A(4, 100) %o A319720 (PARI) a(n) = fromdigits(vecsort(digits(n, 4), , 4), 4); \\ _Michel Marcus_, Sep 26 2018 %Y A319720 b-ary: A073138 (b=2), A319651 (b=3), this sequence (b=4), A319722 (b=5), A319723 (b=6), A319724 (b=7), A319725 (b=8), A319726 (b=9), A004186 (b=10). %Y A319720 Cf. A165012, A319652. %K A319720 nonn,base,easy %O A319720 0,3 %A A319720 _Seiichi Manyama_, Sep 26 2018