[JAVA] Simple & easy to understand DFS
\n    int result = 0;\n    int min = Integer.MAX_VALUE;\n    public int closestCost(int[] baseCosts, int[] toppingCosts, int target) {\n       for (int base : b
```\n    int result = 0;\n    int min = Integer.MAX_VALUE;\n    public int closestCost(int[] baseCosts, int[] toppingCosts, int target) {\n       for (int base : baseCosts)\n\t\t\tdfs(toppingCosts, 0, base, target);\n\t\treturn result;\n    }\n    private void dfs(int[] toppingCosts, int i, int cost, int target) {\n\t\tif (i == toppingCosts.length) {\n\t\t\tif(Math.abs(target-cost) < min){\n\t\t\t\tresult = cost;\n\t\t\t\tmin = Math.abs(target-cost);\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\t\tdfs(toppingCosts, i + 1, cost, target);\n\t\tdfs(toppingCosts, i + 1, cost + toppingCosts[i], target);\n\t\tdfs(toppingCosts, i + 1, cost + toppingCosts[i] * 2, target);\n\t}\n```
['Backtracking', 'Depth-First Search', 'Java']