login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A199988 Numbers whose product of digits is 6. 3

%I #23 Jun 16 2021 10:16:53

%S 6,16,23,32,61,116,123,132,161,213,231,312,321,611,1116,1123,1132,

%T 1161,1213,1231,1312,1321,1611,2113,2131,2311,3112,3121,3211,6111,

%U 11116,11123,11132,11161,11213,11231,11312,11321,11611,12113,12131,12311,13112,13121

%N Numbers whose product of digits is 6.

%H Robert Israel, <a href="/A199988/b199988.txt">Table of n, a(n) for n = 1..10000</a>

%p f:= proc(d) local b,i,t;

%p b:= (10^d-1)/9;

%p op(sort([seq(b+5*10^i,i=0..d-1),seq(b+10^t[1]+2*10^t[2],t = combinat:-permute([$0..d-1],2))]))

%p end proc:

%p seq(f(i),i=1..5); # _Robert Israel_, Jan 13 2021

%t Select[Range[20000], Times @@ IntegerDigits[#] == 6 &] (* _T. D. Noe_, Nov 16 2011 *)

%o (Python)

%o from sympy import prod

%o from sympy.utilities.iterables import multiset_permutations

%o def agen(maxdigits):

%o for digs in range(1, maxdigits+1):

%o for mp in multiset_permutations("1"*(digs-1) + "236", digs):

%o if prod(map(int, mp)) == 6: yield int("".join(mp))

%o print(list(agen(5))) # _Michael S. Branicky_, Jun 16 2021

%Y Subsequence of A034053.

%Y Cf. A007954.

%K nonn,look,base

%O 1,1

%A _Jaroslav Krizek_, Nov 13 2011

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 18 22:18 EDT 2024. Contains 371782 sequences. (Running on oeis4.)