Numbers k such that the last letter of k is the same as the first letter of k+1: Difference between revisions
Numbers k such that the last letter of k is the same as the first letter of k+1 (view source)
Revision as of 01:41, 1 July 2023
, 11 months ago→{{header|Python}}: cleanuup unneeded
(Python example) |
m (→{{header|Python}}: cleanuup unneeded) |
||
Line 330:
except for numbers > 1000 which are divisible by 1000 """
groups = []
while n > 0:
n, r = divmod(n, 1000)
Line 344 ⟶ 342:
def lastletter(n):
return num2words(n)[-1] if
def qualifies(n):
|