The problem is:
Two players take turns removing coins from a pile. There are initially $n$ coins, and on each turn, a player can remove $a_1, a_2, \dotsc, a_k$ coins. The player who cannot remove a coin loses.
To solve it, we can use a recurrence: $$w_n = 1 - w_{n-a_1}w_{n-a_2}\dotsm w_{n-a_k}$$ where $w_n = 1$ if the first player has a winning strategy, and $0$ otherwise. The initial cases can be worked out by hand (or by setting $w_m = 1\ \forall m < 0$ and using the recurrence).
For simple cases like choosing $1, 2, 3, 4$ coins every turn, I could work out the pattern by hand. For an arbitrary case like choosing $3, 7, 8$ coins every turn, I could write a computer program to figure out the pattern.
In every case, there appears to be a pattern; how can I prove this? And how can I figure out the said pattern? Thanks for your attention!
These games are called "finite subtraction games" or "substraction games with a finite subtraction set". As Per Alexandersson mentioned, there are only $2^{a_k}$ sequences of 0s and 1s of a length that could affect the next $w_n$, so the sequence of 0s and 1s must be eventually periodic.
There is actually a lot more that you can say. If you have heard of the Sprague-Grundy theorem, the Grundy values of these games are eventually periodic for the same reason. The patterns for a subtraction set of size 2 are well understood, but I think there's a lot we don't know about the periods for substraction sets of size 3.
CGsuite can be used to calculate the Grundy values easily. For instance, in your example of $\{3,7,8\}$, the values start 0,0,0,1,1,1,0,2,2,1,3 and then repeat 0,0,2,1,1, 0,0,2,1,1, … forever. This corresponds to a sequence of your $w$s of 0,0,0,1,1,1,0,1,1,1,1 and then 0,0,1,1,1, 0,0,1,1,1, …