随笔分类 -  dfs序 、 欧拉序

摘要:Censor frog is now a editor to censor so-called sensitive words (敏感词). She has a long text p . Her job is relatively simple -- just to find the first 阅读全文
posted @ 2018-07-27 23:55 楼主好菜啊 阅读(165) 评论(0) 推荐(0) 编辑
摘要:You are given a tree, it’s root is p, and the node is numbered from 1 to n. Now define f(i) as the number of nodes whose number is less than i in all 阅读全文
posted @ 2018-04-15 15:48 楼主好菜啊 阅读(181) 评论(0) 推荐(0) 编辑
摘要:推荐博客 :https://www.cnblogs.com/stxy-ferryman/p/7741970.html DFS序其实就是一棵树顺次访问的结点的顺序,例如下面这棵树 它的 dfs 序就是 A-B-D-E-G-C-F-H 我们这里的 dfs_[ ] 数组表示的就是这棵树的 dfs 序,s[ 阅读全文
posted @ 2018-04-15 11:27 楼主好菜啊 阅读(310) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示