I know that this question was asked about in PHP but I could not find anything in javascript.
I have a random number generated between 000
(yeah it is just three zero's but it is shown that way from how the number is generated) and 999999999
and I want to test true
or false
for if whether it includes a specific sequence of numbers like 777, 9000, 28, or the like of any length and from any beginning of numbers...
for example, finding 289 in 678342891
or 728987699
would be true
, and finding 289 in 678529187
or 023829564
would be false
.
is this possible, and how would I do it?