上一页 1 ··· 70 71 72 73 74 75 76 77 78 ··· 81 下一页
摘要: [Portal](https://www.luogu.com.cn/problem/P7154) 题意: > 给出两个序列 $a_1,a_2,\dots,a_n$,$b_1,b_2,\dots,b_n$,$i$ 与 $j$ 能匹配当且仅当 $a_i\leq b_j$。 > 定义一个匹配是极大的,当且 阅读全文
posted @ 2020-12-26 15:24 tzc_wk 阅读(104) 评论(0) 推荐(0)
摘要: [Portal](https://codeforces.ml/contest/997/problem/E) 题意: 给出排列 $p_1,p_2,p_3,\dots,p_n$,定义一个区间 $[l,r]$ 是好的当且仅当 $p_l,p_{l+1},p_{l+2},\dots,p_r$ 包含了连续的 $ 阅读全文
posted @ 2020-12-26 14:45 tzc_wk 阅读(277) 评论(0) 推荐(0)
摘要: [题面传送门](https://codeforces.ml/contest/1208/problem/F) 题意:求 $\max\limits_{i using namespace std; #define fi first #define se second #define fz(i,a,b) f 阅读全文
posted @ 2020-12-24 18:09 tzc_wk 阅读(122) 评论(1) 推荐(0)
摘要: [题面传送门](https://codeforces.ml/contest/512/problem/D) 题意: 给出一张无向图,每次你可以选择一个度数 $\leq 1$ 的点并将其删除。 问对于 $k=0,1,2,\dots,n$,有多少个删除 $k$ 个点的序列,答案模 $10^9+9$。 $1 阅读全文
posted @ 2020-12-23 20:55 tzc_wk 阅读(105) 评论(2) 推荐(0)
摘要: [题面传送门](https://codeforces.ml/gym/101480/attachments/download/5837/20152016-acmicpc-central-europe-regional-contest-cerc-15-en.pdf) 题意: 有一个 $10^6\time 阅读全文
posted @ 2020-12-23 00:54 tzc_wk 阅读(109) 评论(1) 推荐(0)
摘要: [题面传送门](https://codeforces.ml/contest/575/problem/A) 题意: 给出 $s_0,s_1,s_2,\dots,s_{n-1}$,对于 $i\geq n$,有 $m$ 个 $s_i$ 满足 $s_i\neq s_{i\bmod n}$,这 $m$ 个 $ 阅读全文
posted @ 2020-12-22 19:55 tzc_wk 阅读(84) 评论(1) 推荐(0)
摘要: - A 不多说了吧,直接扫一遍求出 $r_i>b_i$ 的个数和 $r_i<b_i$ 的个数 - B 稍微打个表找个规律就可以发现,当 $n$ 为奇数的时候,答案为 $\dfrac{(n+1)(n+3)}{2}$,当 $n$ 为偶数的时候,答案为 $(\dfrac{n}{2}+1)^2$。 - C 阅读全文
posted @ 2020-12-20 16:16 tzc_wk 阅读(174) 评论(1) 推荐(0)
摘要: [题面传送门](https://www.luogu.com.cn/problem/P6144) 题意: 给定 $n$ 条线段,第 $i$ 条线段左右端点分别为 $l_i,r_i$ 定义一个线段集合的复杂度为其形成的连通块的个数的 $k$ 次方。 求这 $n$ 条线段所有子集的复杂度之和。 答案对 $ 阅读全文
posted @ 2020-12-20 12:08 tzc_wk 阅读(174) 评论(0) 推荐(0)
摘要: [题面传送门](https://codeforces.ml/contest/702/problem/F) 首先肯定将所有物品排个序。 考虑暴力做法,对于每个询问,枚举所有物品,能买就买。不过扫一眼就知道无法直接优化。 不妨换个角度,暴力做法是枚举询问,这次我们枚举物品。从左到右依次枚举所有物品,将所 阅读全文
posted @ 2020-12-19 01:20 tzc_wk 阅读(93) 评论(0) 推荐(1)
摘要: 现场 1 小时 44 分钟过掉此题,祭之 ![](https://cdn.luogu.com.cn/upload/image_hosting/ia1ukklw.png) 大力分类讨论。 如果 $|s|=1$,那么显然所有位置都只能填上这个字符,因为你只能这么填。 ```cpp scanf("%d", 阅读全文
posted @ 2020-12-19 00:17 tzc_wk 阅读(163) 评论(0) 推荐(0)
上一页 1 ··· 70 71 72 73 74 75 76 77 78 ··· 81 下一页