My idea:
int world [][]={ {1,1,1,1,1},
{1,0,0,F,1},
{1,M,0,0,1},
{1,0,0,P,1},
{1,1,1,1,1} }
Where 1 = boundary (can't walk thru)
0 = paths (can walk thru)
P = person
M = money
F = food
main = person walks to money and puts in pocket. Person then walks to food.
I'm certain when I understand what this looks like in C++, I'll be soon to rule the world.
P.S. How do I make my posts look like code like the rest of you?