Welcome and don't worry about questions! That's how we learn.
Which cast on are you doing? It sounds like you are doing long tail cast on. After you've done this for awhile you can estimate pretty well, but it is hard at first to figure out how much yarn you'll need. The wrap method works pretty well. You wrap whatever yarn you're using around the needle 10 times..that is about how much each cast on stitch takes. After I do this then I estimate how long that is, add another few inches just to be safe and start casting on. It doesn't always work and then you have to start over.
One way to not have to do this is use either two skeins or the inside and outside of the same skein, knot them together and then start the cast on. You can't run out that way. When you are done you can cut one yarn and knit with the other.
You could also just do a knitted cast on and not worry about any of this at least until you're more comfortable with knitting.