Given an unknown graph (or just world), a robot/person should be able to find a way between two points.
Pathfinding is often done on a known world, this website allows you to check out the different algorithms, which very much look like what you want to achieve.
Since you mentioned moving obstacles, you may also look at collision avoidance algorithms. But it depends on if the moving obstacles themselves also avoid collisions. To be able to avoid moving obstacles, you'll have to be able to know their location, direction and speed, to be able to calculate where you would collide (and how to avoid it). But usually, just braking whenever they get too close may just work (maybe even drive backwards if they get even closer).
So, we've got a startpoint and an endpoint. Our initial plan would be to travel straight from start to end, since this is obviously the shortest path.
But it would be ideal if there wasn't an obstacle, and for us to verify our approach, we'll just think of an obstacle. Let's say there is a wall right in front of you, what are you going to do? You can't see where it ends (I believe your robot doesn't), so you're just going to walk around it, you could choose a random way, (left or right, maybe even backwards)
Basically you want to get to the endpoint, so you're going to have an algorithm that has some kind of "fitness" based on how close you are to the endpoint.
- Brute force: Try every single route, until you've found the way.
- Right hand rule: I've heard that, in mazes, if you always hold your right hand against the (right) wall, eventually you'll get to the end.
- Greedy algorithm: Just move towards the point, if you can't go any furhter, choose whatever seems to get you closer. If nothing is getting you any closer, choose the route that moves away the least.
- Heuristic algorithm: Move one way, until choosing another round will be more likely to be a solution, then choose to go down another lane. Until this one seems to be leading you away.
- Search algorithm, like breadth first or depth first search, check this video
Just try some of the algorithms, to see which one works best. Or try to determine/explain why one algorithm is/should be better than the other.