2024年9月22日

Day 22 回溯法part04| LeetCode 491.递增子序列,46.全排列,47.全排列 II

摘要: 491.递增子序列 491. 非递减子序列 class Solution { public List<Integer> path=new LinkedList<>(); public List<List<Integer>> res=new ArrayList<>(); public List<Lis 阅读全文

posted @ 2024-09-22 20:19 FreeDrama 阅读(2) 评论(0) 推荐(0) 编辑

Day 21 回溯法part03| LeetCode 93. 复原 IP 地址,78.子集,90.子集II

摘要: 93. 复原 IP 地址 93. 复原 IP 地址 class Solution { List<String> res=new ArrayList<>(); public List<String> restoreIpAddresses(String s) { backtracking(s,0,0); 阅读全文

posted @ 2024-09-22 17:40 FreeDrama 阅读(4) 评论(0) 推荐(0) 编辑

Day 20 回溯法part02| LeetCode 39. 组合总和 ,40.组合总和II,131.分割回文串

摘要: 39. 组合总和 39. 组合总和 class Solution { public List<List<Integer>> res = new ArrayList<>(); public List<Integer> path = new LinkedList<>(); public List<Lis 阅读全文

posted @ 2024-09-22 17:39 FreeDrama 阅读(5) 评论(0) 推荐(0) 编辑

导航