Asking for food
Asking food is the easiest way to get it free, legally and often also nicely by people. It is the main skill of regular so-called "freeloaders" and shouldn't be taken as a thing to take advantage from..(as neither any other kindness received)
It is also quite simple as it sounds, though lots of people might feel uncomfortable, shy or embarrassed doing it. Often people offer you food so much before than you need to ask them for it..As you are hitchhiking or clearly not behaving as a tourist / person who can spend money you will be offered food so many more times than you espect.
Just go where there is some food, better if the shop is small, family owned, simple. In big malls might be hard because of several "responsibilities" and basically because of a huge lack of kindness due to greed and respect of the law / regular / ordinary western vision of life.. Explain the shopkeeper (fruitseller, baker, etc) your situation of moneyless traveler, talk to him and be friendly, the chances you won't get anything to it are really low and even in that case you can just change shop, wait or fast meanwhile you find somebody nicer.
It will be up to your honesty evaluate if you can't actually afford to spend money for that food (often you'll be making pleasure to the person who offer accepting their offer and watching their smile as confirm of it..) or not, how much of that food you really need (in some country people might be ready to take the food our of their children's mouths to give it to a guest..) according to how "poor" is the person and how big his/her heart is.
The situation can be really awkward and strange from the emotional point of view especially if you are not used to it.