xinyu04

导航

2022年5月15日 #

LeetCode 63 Unique Paths II DP

摘要: You are given an m x n integer array grid. There is a robot initially located at the top-left corner (i.e., grid[0][0]). The robot tries to move to th 阅读全文

posted @ 2022-05-15 23:26 Blackzxy 阅读(16) 评论(0) 推荐(0) 编辑

Leetcode 5 Longest Palindromic Substring DP

摘要: Given a string s, return the longest palindromic substring in s. Solution 设 \(dp[i][j]\) 表示字串 \(s[i,...,j]\) 是否为回文串。初始化时,每个单独的字符本身就是回文串;长度为2的串只要首尾相同,也 阅读全文

posted @ 2022-05-15 02:57 Blackzxy 阅读(7) 评论(0) 推荐(0) 编辑

Leetcode 322 Coin Change DP

摘要: You are given an integer array coins representing coins of different denominations and an integer amount representing a total amount of money. Return 阅读全文

posted @ 2022-05-15 01:20 Blackzxy 阅读(13) 评论(0) 推荐(0) 编辑