OFFSET
1,2
LINKS
Jason Yuen, Table of n, a(n) for n = 1..2000
PROG
(Python)
def dijkstra(dist, start, startValue, traverse): ... # See A077196
def A077194(n):
def traverse(remainder, d):
add1, number = d
return [((remainder*10)%n, (add1, number*10)),
((remainder+1)%n, (add1+1, number+1))]
return dijkstra([(n+1, 0)]*n, 1%n, (1, 1), traverse)[0][1] # Jason Yuen, Feb 28 2024
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Amarnath Murthy, Nov 01 2002
EXTENSIONS
Edited by Robert G. Wilson v, Nov 05 2002
Corrected by Matthew Vandermast, Apr 12 2003
a(34) corrected by Max Alekseyev, Feb 26 2009
a(38) corrected by Paul Tek, Mar 14 2013
STATUS
approved