OFFSET
1,1
MAPLE
positions := proc(e, ll) local a, k, l, m; l := ll; m := 1; a := []; while(member(e, l[m..nops(l)], 'k')) do a := [op(a), (k+m-1)]; m := k+m; od; RETURN(a); end;
MATHEMATICA
Position[With[{k = Sqrt[2]}, Table[Floor[Floor[k^2*j] - k*Floor[k*j]], {j, 0, 300}]], 1] - 1 // Flatten (* Jean-François Alcover, Mar 06 2016 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Feb 03 2001
STATUS
approved