A088118 Duplicate of A088117.
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 0, 3, 6, 9
Offset: 0
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.
a(341) = max(34*1,3*41) = 123.
a035930 n | n < 10 = 0 | otherwise = maximum $ zipWith (*) (map read $ init $ tail $ inits $ show n) (map read $ tail $ init $ tails $ show n) -- Reinhard Zumkeller, Aug 14 2011
a:= proc(n) local l, m; l:= convert(n, base, 10); m:= nops(l); `if`(m<2, 0, max(seq(parse(cat(seq(l[m-i], i=0..j-1))) *parse(cat(seq(l[m-i], i=j..m-1))), j=1..m))) end: seq(a(n), n=0..120); # Alois P. Heinz, May 22 2009
Flatten[With[{c=Range[0,9]},Table[c*n,{n,0,10}]]] (* Harvey P. Dale, Jun 07 2012 *)
apply( {A035930(n)=if(n>9,vecmax([vecprod(divrem( n,10^j))|j<-[1..logint(n,10)]]))}, [0..111]) \\ M. F. Hasler, Sep 01 2021
def a(n): s = str(n) return max((int(s[:i])*int(s[i:]) for i in range(1, len(s))), default=0) print([a(n) for n in range(108)]) # Michael S. Branicky, Sep 01 2021
For n<10, a(n) = n*0 = 0, since removing the initial and only digit leaves nothing, i.e., zero (by convention). a(10) = 1*0 = 0, a(12) = 1*2 = 2, ..., a(20) = 2*0 = 0, a(21) = 2*1 = 2, a(22) = 2*2 = 4, ... a(99) = 9*9 = 81, a(100) = 1*00 = 0, a(101) = 1*01 = 1, ..., a(123) = 1*23, ...
a:= n-> `if`(n<10, 0, (s-> parse(s[1])*parse(s[2..-1]))(""||n)): seq(a(n), n=0..120); # Alois P. Heinz, Feb 12 2024
Table[Times@@FromDigits/@TakeDrop[IntegerDigits@n,1],{n,0,103}] (* Giorgos Kalogeropoulos, Sep 03 2021 *)
apply( {A257297(n)=vecprod(divrem(n,10^logint(n+!n,10)))}, [0..111]) \\ Edited by M. F. Hasler, Sep 01 2021
def a(n): s = str(n); return 0 if len(s) < 2 else int(s[0])*int(s[1:]) print([a(n) for n in range(104)]) # Michael S. Branicky, Sep 01 2021
a(1234) = 234 + 2*134 + 3*124 + 4*123 = 1366.
Join[{0},Table[Total[IntegerDigits[n]Table[FromDigits[Drop[ IntegerDigits[ n],{d}]],{d,IntegerLength[n]}]],{n,100}]] (* Harvey P. Dale, Dec 23 2021 *)
a(n) = {v=digits(n);sum(k=1,#v,v[k]*(n\10^(#v-k+1)*10^(#v-k)+n%10^(#v-k)));} \\ Jinyuan Wang, Aug 01 2019
read("transforms") : A330633 := proc(n) local dgs,L,i ; if n <=9 then 0; else dgs := ListTools[Reverse](convert(n,base,10)) ; L := [] ; for i from 2 to nops(dgs) do L := [op(L), op(i-1,dgs)*op(i,dgs)] ; end do: digcatL(L) ; end if; end proc: # R. J. Mathar, Jan 11 2020
Array[If[Or[# == 0, IntegerLength@ # == 1], 0, FromDigits[Join @@ IntegerDigits[Times @@ # & /@ Partition[IntegerDigits@ #, 2, 1]]]] &, 81, 0] (* Michael De Vlieger, Dec 23 2019 *)
a(n) = my(d=digits(n), s="0"); for (k=1, #d-1, s=concat(s, d[k]*d[k+1])); eval(s); \\ Michel Marcus, Apr 28 2020
The number n = 112 is the concatenation of 1 and 12, or of 11 and 2, with respective products 1*12 = 12 and 11*2 = 22. Hence, a(112) = 12, while A035930(112) = 22.
apply( {A347470(x,t(b,c)=if(c\10<=b%c,b\c*(b%c),c>10,oo))= if(x>9,vecmin(vector(logint(x,10),j,t(x,10^j))))}, [0..112])
Comments