Why do bad things happen to good people? The same reason why good things happen to bad people. We will never know.
Speaking from my own experience, I don't take being a Christian to mean that I will be blessed all the time and only good things will happen to me. I know that sometimes, not so good things will happen to me. And those moments, moments in which things don't work out the way I think or believe they should, keep me grounded and drawn towards God. In those times, I come to realize the brevity of my being and the frailty of life, and I find myself drawing closer to the only thing I know real and reliable - God himself. To put it simply, it is a humbling experience.
Philosophical reasoning aside, I personally don't know why God inflicts pain in the form of starvation and poverty on the many peoples on the earth (And I have a problem when people start framing their sentences as God "inflicting" something on someone, because that phrasing itself already sets the up observer against God). But I do know that blaming God for the injustices of this world, most of which are man-made, is a futile effort. You can do it all you want but it's not going to bring you any sort of satisfaction. Besides, the earth is a fallen place, full of sinners like me. If you are straight up denying God and the tenets of faith like truth, righteousness and justice, yet expect God to answer to your question, I don't know man, maybe it's time to read a book.