check string inside string
hey ive got a program which checks winning combination inside a main string.
so for example if the main string is 12376 and i check the the winning combination of "123" i can find it using the string.indexof method however sometimes its not that simple and the main string might be 12763 (as an example)
is there a method or way inwhich i can check to see if a string contains the winning combination even when it may be jumbled up like above?
id also like to mention that 123 isnt the only winning combination im checking, im just using it as an example