STATUS
proposed
approved
proposed
approved
editing
proposed
Array[IfWhich[GCD[#, 10] =!= 1, -1, Mod[#, 3] == 0, Block[{k = 1}, While[Mod[k, #] != 0, k = 10 k + 1]; k], True, (10^MultiplicativeOrder[10, #] - 1)/9] &, 42] (* Michael De Vlieger, Dec 11 2020 *)
Array[If[GCD[#, 10] == 1, Block[{k = 1}, While[Mod[k, #] != 0, k = 10 k + 1]; k], -1] &, 42] (* Michael De Vlieger, Dec 11 2020 *)
proposed
editing
editing
proposed
Cf. A190301 (multiplier).
proposed
editing
editing
proposed
rem = (rem*10 + 1) % n
proposed
editing