So I get how to find the number of ways of getting a number with $2$ sets of numbers (ex: using $1$s and $2$s to get $10$). But I have no clue where to start to figure out how many ways to get a number using $3$ sets of numbers:
How many ways can you add to $50$ by using $1$s, $4$s, and $6$s?
Order matters and they count as a way ($1+4$ and $4+1$ is $2$ ways), but all $1$s or all $2$s in different orders count as one way ($1+1$ and $1+1$ is $1$ way).
Is there like a formula that I could use to figure this out? Thanks.
From the comments:
I tried using brute force with 2 numbers and found a pattern where the next number of ways = number of ways now + previous number of ways. But using brute force with 3 numbers I'm cant seem to find a pattern.