羽原默研

导航

总结

https://www.luogu.com.cn/problem/P4913 比较简单的二叉树深度问题;

https://www.luogu.com.cn/problem/P5076 两种解法:一种是按题意的线段树求解,这种比较麻烦,另一种则是使用stl容器中的multiset暴力解决。

https://www.luogu.com.cn/problem/P1305 简单的二叉树前序遍历。

https://www.luogu.com.cn/problem/P1030 可以通过后序遍历最后一个遍历的节点是根节点的思路来解决。

https://www.luogu.com.cn/problem/P3884 二叉树的建立以及LCA算法。

https://www.luogu.com.cn/problem/P1241 一开始还以为是栈,然后发现根据题意写递归就行(乐)

https://www.luogu.com.cn/problem/P1160 一个线性结构模拟题。

https://www.luogu.com.cn/problem/P1540 水题队列

https://www.luogu.com.cn/problem/P1280 感觉这题思路其实比较简单,主要就是反着来,因为正着时间来找不出解,反着时间来,同时把任务的开始时间倒序(从大到小)然后注意标记当前任务即可。

https://www.luogu.com.cn/problem/P2758 字符串动规题,根据dp[i][j]对于字符串a的前i个字母变成字符串b的前j个字母需要最少的步数。然后注意三种方法的i和j的变化即可。

 

posted on 2022-09-09 10:07  羽原默研  阅读(71)  评论(0)    收藏  举报