Not all are like this. I started offering to buy food and some seem grateful and accept, others become belligerent.
You can make a lot of money in a day standing at a busy traffic signal getting dollars from people, more than you can make working for minimum wage for a day.
So I mostly quit giving cash, except in cases where I have been travelling and the person I've met provided a useful service or local knowledge to me as a tourist/foreigner.