登录
数字k使0和5并列出现在k的base-6表示中,但不出现在k+1中。
0

%I#25 2021年8月25日04:54:40

%S 30,41,66,77102113138149174185210221251257282293318329,

%电话:354365390401426437467473498509534545570581606617642,

%电话:653683689714725750761786797822833

%N数字k,使得0和5并列出现在k的base-6表示中,但不出现在k+1中。

%e 30(10)=50(6)但31(10)=51(6),因此30在序列中。

%t Transpose[SequencePosition[Table[If[Sequence Count[IntegerDigits[n,6],{0,5}]>0||SequenceCount[integerDiges[n,6m],{5,0}]>0,1,0],{n,1000}],{1,0}][1](*程序使用Mathematica版本10*中的SequencePosition和SequenceCount函数)(*Harvey P.Dale_,2016年1月14日*)

%o(鼠尾草)

%o@cached_function(缓存函数)

%o定义str_base6(x):

%o返回“”.join(str(y)for y in x.digits(base=6))

%o[1..2000]中x的x,如果str_base6(x)中为“50”,或str_base5(x)为“05”,而不是(str_base 6(x+1)中为‘50’,或str_ base6(x/1)中为'05')]

%o#Tom Edgar,2014年5月13日

%Y参考A007092。

%K非n,碱基

%O 1,1号机组

%《百灵鸟金伯利》,1999年12月11日