Tray Bien: Difference between revisions
Jump to navigation
Jump to search
imported>Kmk21 No edit summary |
imported>Kmk21 No edit summary |
||
Line 3: | Line 3: | ||
This is a pretty standard DP problem. The idea is that we systematically fill from the left and track how many ways the "front' of trays can look. It turns out there are 7: | This is a pretty standard DP problem. The idea is that we systematically fill from the left and track how many ways the "front' of trays can look. It turns out there are 7: | ||
< | <pre> | ||
# | # | ||
# | # | ||
Line 35: | Line 35: | ||
X | X | ||
X | X | ||
</ | </pre> |
Revision as of 01:43, 7 November 2017
This problem asks us to fill a 3-by-x foot space with trays of 2x1 or 1x1 and report back the number of ways to do it.
This is a pretty standard DP problem. The idea is that we systematically fill from the left and track how many ways the "front' of trays can look. It turns out there are 7:
# # # X # # # X # # # X X X # X # X # X X X X X