Search the courses, subjects, tracks, games and features, or jump straight to a page.
3 cards from this section. Quick, good the night before a test.
If you are at (0,0), how many paths are there to (0,0)?
Consider what it means to stay in the same place.
Name two ways you can reach the point (2,1) in a grid starting from (0,0).
Think about moving in increments of 1.
What is the formula for calculating paths to point (i,j) in a grid?
Think about where you can move to reach (i,j).
True or False: In a grid with holes, all path values are affected by zero values.
Consider the flow of paths in relation to holes.
Given a 5x5 grid with holes at (2,2) and (3,3), write a function to compute paths from (0,0) to (4,4) programmatically. Show your results for multiple layouts of holes.
Map out the grid with a two-dimensional array for ease.
Describe a scenario where using memoization might fail compared to dynamic programming when adding complexity (like adding more holes or larger grid sizes).
Consider performance and time with increasing complexity in problem.
5 more questions in this section. Enroll free to practise them all.
Enroll free