摘要: 题意:给一棵n(1≤n≤200000个叶子的二叉树,可以交换每个点的左右子树,要求前序遍历叶子的逆序对最少。 算法见注释 cpp include define ll long long using namespace std; const int N=5e6+6; int n,tot; int lc 阅读全文
posted @ 2019-06-07 21:53 Sshwy 阅读(149) 评论(0) 推荐(0)