The method of just discarding the numbers outside the range is the method that is, simple, easy to prove correct, adaptable, least susceptible to subtle errors, and the one you should use.
For all practical purposes, stop reading, and go to this answer and embrace its contents
What if you do want to waste as few of those bits as possible though?
What you have then is the opposite problem of an entropy coder. An entropy coder takes numbers following some statistical distribution, and turns them into a stream of bits with as close to 1 bit of entropy per bit as possible. You have a stream of 1 bit of entropy per bit, and want to turn it into numbers with some distribution, the opposite operation.
That's what the decoding part of an entropy coding scheme does.
So what you would do is do the decoding stage of arithmetic coding, give it a statistical distribution of equal weights in the range 0-100, and feed it random bits as an input instead of an encoded file.
An arithmetic coder with 31-bit symbol tables should give you a waste fraction of $\approx 2 \cdot 10^{-8}$, at which point the 32 bits of warmup padding would be the greatest source of waste for your 1 million bits.
This is not a good idea in practice:
While this conversion is reasonably fast due to entropy coders being used in performance critical software like video encoding, this speed is very often a compromise originating from the entropy coders leaking entropy in all kind of little ways.
- This if fine for compression. Getting files a few bits larger than optimality is no big deal if decompression is quicker.
- This is absolutely not fine for crypto! Getting subtly skewed distributions would be fatal.
I have seen non-leaky arithmetic coders, in an academic setting, maybe once or twice. I have seen dozens more leaking, both intentionally (performance) or unintentionally.