|
Search: id:A117644
|
|
|
| A117644 |
|
Number of different couples of different numbers, with digits different from zero, that produce a sum equal to 10, 100, 1000, 10000, 100000, 1000000, etc. |
|
+0 2
|
| |
|
|
OFFSET
|
0,1
|
|
|
EXAMPLE
|
Es. 10 = 1 + 9 = 2 + 8 = 3 + 7 = 4 + 6 therefore we have 4 different couples
9 + 1 is not considered because is the same couple as 1 + 9
5 + 5 is not considered because we consider couples with different numbers
|
|
MAPLE
|
P:=proc(n)local i, j, k, ok, count; count:=0; for i from 1 by 1 to n/2-1 do ok:=0; k:=i; while k>0 do j:=frac(k/10)*10; if j=0 then ok:=1; fi; k:=trunc(k/10); od; k:=n-i; while k>0 do j:=frac(k/10)*10; if j=0 then ok:=1; fi; k:=trunc(k/10); od; if ok=1 then count:=count+1; fi; od; print(n/2-1-count); end: P(1000);
|
|
CROSSREFS
|
Sequence in context: A120075 A123650 A122910 this_sequence A055602 A073565 A039657
Adjacent sequences: A117641 A117642 A117643 this_sequence A117645 A117646 A117647
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
Paolo P. Lava & Giorgio Balzarotti (ppl(AT)spl.at), Apr 10 2006
|
|
|
Search completed in 0.002 seconds
|