(int[] cost, int[] time)
| 1 | class Solution { |
| 2 | Map<String, Integer> dp; |
| 3 | public int paintWalls(int[] cost, int[] time) { |
| 4 | int n = cost.length; |
| 5 | dp = new HashMap<>(); |
| 6 | return dfs(0, cost.length, cost, time); |
| 7 | } |
| 8 | private int dfs(int i, int remain, int[] cost, int[] time){ |
| 9 | if(remain <= 0) |
| 10 | return 0; |