上一页 1 2 3 4 5 6 7 8 9 10 ··· 42 下一页
摘要: https://blog.csdn.net/qq_45721778/article/details/104560736 阅读全文
posted @ 2022-04-06 19:46 智人心 阅读(31) 评论(0) 推荐(0)
摘要: class Solution { public: bool isMatch(string s, string p) { memset(dp,false,sizeof(dp)); int ns = s.size(),np = p.size(); bool flag; for(int i=1;i<ns; 阅读全文
posted @ 2022-01-06 17:24 智人心 阅读(34) 评论(0) 推荐(0)
摘要: class Solution { public: vector<vector<int>> combinationSum(vector<int>& candidates, int target) { sort(candidates.begin(),candidates.end()); vector<v 阅读全文
posted @ 2022-01-05 17:07 智人心 阅读(30) 评论(0) 推荐(0)
摘要: class Solution { public: void solveSudoku(vector<vector<char>>& board) { for(int i=0;i<9;i++){ for(int j=0;j<9;j++){ if(board[i][j]!='.'){ mt[0][i][bo 阅读全文
posted @ 2022-01-03 21:28 智人心 阅读(28) 评论(0) 推荐(0)
摘要: class Solution { public: int longestValidParentheses(string s) { int n = s.size(),i = 0,maxResult = 0,result = 0,t,tmax,tsum; if(n==0)return 0; stack< 阅读全文
posted @ 2022-01-02 19:57 智人心 阅读(34) 评论(0) 推荐(0)
摘要: class Solution { public: vector<int> findSubstring(string s, vector<string>& words) { vector<int>v; string t; int n = s.size(),n2 = words.size(),n3 = 阅读全文
posted @ 2022-01-02 15:30 智人心 阅读(28) 评论(0) 推荐(0)
摘要: class Solution { public: vector<vector<int>> threeSum(vector<int>& nums) { vector<vector<int>>v; vector<int>v2; sort(nums.begin(),nums.end()); int n = 阅读全文
posted @ 2021-12-30 14:50 智人心 阅读(24) 评论(0) 推荐(0)
摘要: class Solution { public: int maxArea(vector<int>& height) { int i = 0,j = height.size()-1,result = 0; while(i<j){ int h = min(height[i],height[j]); re 阅读全文
posted @ 2021-12-30 09:37 智人心 阅读(22) 评论(0) 推荐(0)
摘要: double findMedianSortedArrays(int* nums1, int nums1Size, int* nums2, int nums2Size){ int i = 0,p = 0,q = 0,n1 = nums1Size+nums2Size,n = (nums1Size+num 阅读全文
posted @ 2021-12-29 17:56 智人心 阅读(25) 评论(0) 推荐(0)
摘要: #include<iostream> #include<cstring> using namespace std; #define maxn 1005 #define inf 0x3f3f3f3f int data[maxn][maxn],n,dis[maxn],vis[maxn]; int Dij 阅读全文
posted @ 2021-12-13 21:35 智人心 阅读(26) 评论(0) 推荐(0)
上一页 1 2 3 4 5 6 7 8 9 10 ··· 42 下一页