fortune cookies have the "learn chinese" words on the back of the little piece of paper inside. how many would i have to open to learn the whole language of chinese?

This is a complex question. You need to know 3000 characters (or ideograms) to read the Chinese newspaper, but Chinese has way more than 3000 words, you need to know combinations of ideograms. A well-known 12-volume reference Chinese dictionary lists over 370,000 different word definitions, but I don’t think you would find all of them in fortune cookies! A common 1-volume dictionary lists about 80,000 different words in Chinese (and 11,000 ideograms).

Now back to your question: you would then need to open at least that many different cookies to learn Chinese, but assuming that you are going to the restaurant and getting cookies randomly, this is a different probabilistic problem : how many cookies would you need to open on average to sample all the Chinese words? The answer is way way more than that, because you will most likely pick up the same word several times over. The precise answer is probably meaningless.