Skip to main content
deleted 1 character in body
Source Link
lesobrod
  • 3.4k
  • 1
  • 7
  • 27

Wolfram Language (Mathematica), 6058 bytes

(a={x=2};Do[While[Mod[Times@@a;Do[While@Mod[Times@@a,++x]==0];AppendTo[a++x]==0;AppendTo[a,x],#];a)&

Try it online!

Print given number of sequence members.
Based on the next statement from Wiki:

Another way of defining this sequence is that each element is the smallest positive integer that does not divide the product of all of the previous elements of the sequence.

Wolfram Language (Mathematica), 60 bytes

(a={x=2};Do[While[Mod[Times@@a,++x]==0];AppendTo[a,x],#];a)&

Try it online!

Print given number of sequence members.
Based on the next statement from Wiki:

Another way of defining this sequence is that each element is the smallest positive integer that does not divide the product of all of the previous elements of the sequence.

Wolfram Language (Mathematica), 58 bytes

(a={x=2};Do[While@Mod[Times@@a,++x]==0;AppendTo[a,x],#];a)&

Try it online!

Print given number of sequence members.
Based on the next statement from Wiki:

Another way of defining this sequence is that each element is the smallest positive integer that does not divide the product of all of the previous elements of the sequence.

[Edit removed during grace period]
Source Link
lesobrod
  • 3.4k
  • 1
  • 7
  • 27
Source Link
lesobrod
  • 3.4k
  • 1
  • 7
  • 27

Wolfram Language (Mathematica), 60 bytes

(a={x=2};Do[While[Mod[Times@@a,++x]==0];AppendTo[a,x],#];a)&

Try it online!

Print given number of sequence members.
Based on the next statement from Wiki:

Another way of defining this sequence is that each element is the smallest positive integer that does not divide the product of all of the previous elements of the sequence.