fork(3) download
  1. f=@(x,y)(1:--x)*~all(mod(1:x,y),1)'
  2.  
  3. f(50,2)
  4. f(10,[3;5])
  5. f(28,[4;2])
  6. f(19,[7;5])
  7. f(50,[2;3;5])
Success #stdin #stdout 0.22s 103360KB
stdin
Standard input is empty
stdout
f =

@(x, y) 1:--x * !all (mod (1:x, y), 1)'

ans =  600
ans =  23
ans =  182
ans =  51
ans =  857