摘要:
仅供自己学习 题目: In a N x N grid composed of 1 x 1 squares, each 1 x 1 square consists of a /, \, or blank space. These characters divide the square into co 阅读全文
posted @ 2021-01-25 21:51
Mrsdwang
阅读(74)
评论(0)
推荐(0)
摘要:
仅供自己学习 题目: Given a string s, return the longest palindromic substring in s. 思路: 1.暴力求解,每个元素都遍历一遍,获得的每个子串都逆向遍历一边比较是否相等,RT为O(n^3) 2.中心扩展法。每个元素从两侧扩展,如果左右 阅读全文
posted @ 2021-01-25 16:41
Mrsdwang
阅读(66)
评论(0)
推荐(0)

浙公网安备 33010602011771号