-1

I'm trying to create the random varible and them indicate that stops at the variable number.

var x;

function myFunction() {
    var x = Math.floor(Math.random() * 2000);
}

sym.stop('x');
showdev
  • 28,454
  • 37
  • 55
  • 73

1 Answers1

0

X is a variable, not a string. Remove the ' ' around x on the last line.

var x = Math.floor(Math.random() * 2000);
sym.stop(x);
Rick Burns
  • 1,538
  • 16
  • 20