posted @ 2025-04-10 11:09
ZhangZhihuiAAA
阅读(6)
推荐(0)
摘要:
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 @ 2025-04-09 19:28
ZhangZhihuiAAA
阅读(19)
推荐(0)
摘要:
Given a m x n grid filled with non-negative numbers, find a path from top left to bottom right, which minimizes the sum of all numbers along its path.
阅读全文
posted @ 2025-04-08 21:15
ZhangZhihuiAAA
阅读(20)
推荐(0)
摘要:
>>> m, n = 3, 4 >>> grid = [[float('inf')] * n] * m >>> grid [[inf, inf, inf, inf], [inf, inf, inf, inf], [inf, inf, inf, inf]] >>> for j in range(n):
阅读全文
posted @ 2025-04-08 21:09
ZhangZhihuiAAA
阅读(15)
推荐(0)
摘要:
Given a triangle array, return the minimum path sum from top to bottom. For each step, you may move to an adjacent number of the row below. More forma
阅读全文
posted @ 2025-04-08 20:35
ZhangZhihuiAAA
阅读(24)
推荐(0)
摘要:
Given an integer array nums, return the length of the longest strictly increasing subsequence. Example 1: Input: nums = [10,9,2,5,3,7,101,18] Output:
阅读全文
posted @ 2025-04-08 19:38
ZhangZhihuiAAA
阅读(12)
推荐(0)
摘要:
You are given an integer array coins representing coins of different denominations and an integer amount representing a total amount of money. Return
阅读全文
posted @ 2025-04-08 18:51
ZhangZhihuiAAA
阅读(35)
推荐(0)
摘要:
Given a string s and a dictionary of strings wordDict, return true if s can be segmented into a space-separated sequence of one or more dictionary wor
阅读全文
posted @ 2025-04-07 19:05
ZhangZhihuiAAA
阅读(19)
推荐(0)
摘要:
You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed, the only constraint stopping yo
阅读全文
posted @ 2025-04-07 17:18
ZhangZhihuiAAA
阅读(17)
推荐(0)
摘要:
You are climbing a staircase. It takes n steps to reach the top. Each time you can either climb 1 or 2 steps. In how many distinct ways can you climb
阅读全文
posted @ 2025-04-07 17:13
ZhangZhihuiAAA
阅读(16)
推荐(0)