leetcode.cn 2026-09-28
🟢1614.maximum-nesting-depth-of-the-parentheses
🏷️ Tags
#stack #string #bracket_sequences
🟢1614.maximum-nesting-depth-of-the-parentheses
🏷️ Tags
#stack #string #bracket_sequences
Telegraph
maximum-nesting-depth-of-the-parentheses
给定 有效括号字符串 s,返回 s 的 嵌套深度。嵌套深度是嵌套括号的 最大 数量。 示例 1: 输入:s = "(1+(2*3)+((8)/4))+1" 输出:3 解释:数字 8 在嵌套的 3 层括号中。 示例 2: 输入:s = "(1)+((2))+(((3)))" 输出:3 解释:数字 3 在嵌套的 3 层括号中。 示例 3: 输入:s = "()(())((()()))" 输出:3 提示:
leetcode.com 2026-09-28
🟢1614.maximum-nesting-depth-of-the-parentheses
🏷️ Tags
#stack #string #bracket_sequences
🟢1614.maximum-nesting-depth-of-the-parentheses
🏷️ Tags
#stack #string #bracket_sequences
Telegraph
maximum-nesting-depth-of-the-parentheses
Given a valid parentheses string s, return the nesting depth of s. The nesting depth is the maximum number of nested parentheses. Example 1: Input: s = "(1+(2*3)+((8)/4))+1" Output: 3 Explanation: Digit 8 is inside of 3 nested parentheses in the string.…
leetcode.cn 2026-09-29
🔴2267.check-if-there-is-a-valid-parentheses-string-path
🏷️ Tags
#array #dynamic_programming #matrix #bracket_sequences
🔴2267.check-if-there-is-a-valid-parentheses-string-path
🏷️ Tags
#array #dynamic_programming #matrix #bracket_sequences
Telegraph
check-if-there-is-a-valid-parentheses-string-path
一个括号字符串是一个 非空 且只包含 '(' 和 ')' 的字符串。如果下面 任意 条件为 真 ,那么这个括号字符串就是 合法的 。
leetcode.com 2026-09-29
🔴2267.check-if-there-is-a-valid-parentheses-string-path
🏷️ Tags
#array #dynamic_programming #matrix #bracket_sequences
🔴2267.check-if-there-is-a-valid-parentheses-string-path
🏷️ Tags
#array #dynamic_programming #matrix #bracket_sequences
Telegraph
check-if-there-is-a-valid-parentheses-string-path
A parentheses string is a non-empty string consisting only of '(' and ')'. It is valid if any of the following conditions is true:
leetcode.cn 2026-09-30
🟡1111.maximum-nesting-depth-of-two-valid-parentheses-strings
🏷️ Tags
#stack #string #bracket_sequences
🟡1111.maximum-nesting-depth-of-two-valid-parentheses-strings
🏷️ Tags
#stack #string #bracket_sequences
Telegraph
maximum-nesting-depth-of-two-valid-parentheses-strings
如果一个字符串仅由字符 "(" 和 ")" 组成,并且满足以下条件,则称为有效括号字符串(VPS):
leetcode.com 2026-09-30
🟡1111.maximum-nesting-depth-of-two-valid-parentheses-strings
🏷️ Tags
#stack #string #bracket_sequences
🟡1111.maximum-nesting-depth-of-two-valid-parentheses-strings
🏷️ Tags
#stack #string #bracket_sequences
Telegraph
maximum-nesting-depth-of-two-valid-parentheses-strings
A string is a valid parentheses string (denoted VPS) if and only if it consists of "(" and ")" characters only, and:
leetcode.com 2026-10-02
🟡22.generate-parentheses
🏷️ Tags
#string #dynamic_programming #backtracking #bracket_sequences
🟡22.generate-parentheses
🏷️ Tags
#string #dynamic_programming #backtracking #bracket_sequences
Telegraph
generate-parentheses
Given n pairs of parentheses, write a function to generate all combinations of well-formed parentheses. Example 1: Input: n = 3 Output: ["((()))","(()())","(())()","()(())","()()()"] Example 2: Input: n = 1 Output: ["()"] Constraints:
leetcode.cn 2026-10-03
🔴32.longest-valid-parentheses
🏷️ Tags
#stack #string #dynamic_programming #bracket_sequences
🔴32.longest-valid-parentheses
🏷️ Tags
#stack #string #dynamic_programming #bracket_sequences
Telegraph
longest-valid-parentheses
给你一个只包含 '(' 和 ')' 的字符串,找出最长有效(格式正确且连续)括号 子串 的长度。 左右括号匹配,即每个左括号都有对应的右括号将其闭合的字符串是格式正确的,比如 "(()())"。 示例 1: 输入:s = "(()" 输出:2 解释:最长有效括号子串是 "()" 示例 2: 输入:s = ")()())" 输出:4 解释:最长有效括号子串是 "()()" 示例 3: 输入:s = "" 输出:0 提示:
leetcode.com 2026-10-03
🔴32.longest-valid-parentheses
🏷️ Tags
#stack #string #dynamic_programming #bracket_sequences
🔴32.longest-valid-parentheses
🏷️ Tags
#stack #string #dynamic_programming #bracket_sequences
Telegraph
longest-valid-parentheses
Given a string containing just the characters '(' and ')', return the length of the longest valid (well-formed) parentheses substring. Example 1: Input: s = "(()" Output: 2 Explanation: The longest valid parentheses substring is "()". Example 2: Input:…