I was given the following question:

I thought of the problem like this. Each of the $50$ states represents a box, and I want $100$ people in the same box. By the pigeon-hole principle, we are trying to find $N/50 \geq 100 \Longrightarrow N = 50*100 = 5000$. It turns out I was close, my textbook gave the answer $4,951$ and I'm wondering why I was wrong?
What version of the pigeonhole principle are you using? There are various ways of doing it with floor and/or ceiling functions, but IMHO the simplest version is the one involving strict inequalities.
In your problem you want to end up with at least $100$ objects in the same box, that is, more than $99$, so $k=99$. Clearly you have $n=50$ boxes. To guarantee what you want, you need more than $50\times99$ objects altogether, so the smallest possibility is $50\times99+1$.