I want to see more about this program you're supposed to write. You've gotten my interest because I've read a few path-finder and line-of-sight algorithems.
Its actually not that interesting. Its a path finder.
Summary: the cookie monster is on a grid full of cookies (lucky bastard). For some reason, he can't eat all of them, because he can only move down or right (I'm gonna assume he has some injury or something or is too stupid to just eat them all). Starting in the top left corner, he must move to the lower right, eating as many cookies as possible. Some spots on the grid are marked with a -1 which represents a barrel. Barrel's are bad because they're not cookies, therefore, he cannot go to a square with barrels. The goal is to find the path which gives the most cookies and print out how many cookies it gives out (not required to print out the path). We had to use stacks and queues to do it. not that bad though.
Comments 3
Reply
Reply
Summary: the cookie monster is on a grid full of cookies (lucky bastard). For some reason, he can't eat all of them, because he can only move down or right (I'm gonna assume he has some injury or something or is too stupid to just eat them all). Starting in the top left corner, he must move to the lower right, eating as many cookies as possible. Some spots on the grid are marked with a -1 which represents a barrel. Barrel's are bad because they're not cookies, therefore, he cannot go to a square with barrels. The goal is to find the path which gives the most cookies and print out how many cookies it gives out (not required to print out the path). We had to use stacks and queues to do it. not that bad though.
Reply
Leave a comment