摘要: 题目链接:https://www.acwing.com/problem/content/1931/ 个人题解: 点击查看代码 #include <iostream> #include <cstring> #include <algorithm> using namespace std; int dx 阅读全文
posted @ 2022-04-20 21:16 黑VS白-清墨 阅读(21) 评论(0) 推荐(0)
摘要: 三道题 第一题 题目链接:https://leetcode-cn.com/problems/add-strings/ 个人题解:大整数相加板子题 点击查看代码 class Solution { public: vector<int> add(vector<int>& A, vector<int>& 阅读全文
posted @ 2022-04-20 17:23 黑VS白-清墨 阅读(56) 评论(0) 推荐(0)
摘要: 题目链接:https://leetcode-cn.com/problems/longest-absolute-file-path/ 个人题解:栈模拟,找到每一个换行符即可 代码: class Solution { public: int lengthLongestPath(string input) 阅读全文
posted @ 2022-04-20 17:12 黑VS白-清墨 阅读(12) 评论(0) 推荐(0)
摘要: 题目链接:https://www.acwing.com/problem/content/description/1355/ 个人题解: 我们对 \(1-100\) 以内所有的 \([l,r]\) 区间进行枚举,其中 \(r-l=17\) 在这个区间的控制下,我们对每座山峰进行“修剪”,保证其高度在 阅读全文
posted @ 2022-04-20 07:15 黑VS白-清墨 阅读(22) 评论(0) 推荐(0)