码迷,mamicode.com
首页 >  
搜索关键字:gym    ( 996个结果
CF Gym-101911A Coffee Break
题目:https://vjudge.net/problem/Gym-101911A 题意:n、m、d分别表示Mo想休息的次数、每天最大的工作时长以及两次休息的最小间隔,ai为Mo想休息的时刻,每次休息一分钟,求休息n次所需的最少天数,以及按所给顺序每个时刻所在的天的下标。 分析:贪心。定义一个结构体 ...
分类:其他好文   时间:2020-03-14 21:43:21    阅读次数:51
Gym - 100712H
Gym - 100712H tarjan无向图缩点+树上直径 #include<iostream> #include<cstdio> #include<queue> #include<algorithm> #include<cmath> #include<ctime> #include<set> # ...
分类:其他好文   时间:2020-03-11 23:56:54    阅读次数:100
CF::Gym 100113K - The Merry Student Life During the Term. . .
"CF::Gym题目页面传送门" 有$n$组任务,每组$m_i$个,第$i$组第$j$个任务的编号为$\sum\limits_{k=1}^{i 1}m_k+j$。第$i$个任务需要$a_i$个单位时间完成。刚开始时刻为$0$,每完成一个任务$i$当前的时刻就增加$a_i$。若第$i$个任务完成的时刻 ...
分类:其他好文   时间:2020-03-11 18:09:46    阅读次数:64
G. Minimax 二维区域中的最值
https://codeforces.com/gym/101972/problem/G 求二维的一片区域中的最大最小值。 #include<bits/stdc++.h> #define endl '\n' #define _for(i,a,b) for(int i=a;i<b;i++) using ...
分类:其他好文   时间:2020-03-10 16:15:04    阅读次数:55
Gym 100340A Cookies
https://codeforces.com/gym/100340/problem/A 题目 老人给n个小学生发m个饼干,每人最少一个,最后都发完了。这些小学生每个人都有一个贪心值g,如果有x个人的饼干比他多,那么他的不高兴指数就是$gx$ 给出n,m,所有贪心值,输出不高兴指数的和的最小值,同时输 ...
分类:其他好文   时间:2020-03-04 23:08:47    阅读次数:57
Galactic Collegiate Programming Contest Gym - 101572G 模拟
#include<bits/stdc++.h> using namespace std; int n,m; struct node { int id; int slove; int pen; bool operator<(const node &b)const { //如果解决的数量和罚时都一样,就 ...
分类:其他好文   时间:2020-02-23 14:46:28    阅读次数:64
2019-2020 ICPC Southwestern European Regional Programming Contest (SWERC 2019-2020)
J想到了卡特兰数,也想到要按最小值分割数组,丢给队友之后两个人都没做出来,傻了 题目链接:https://codeforces.com/gym/102501 B: solver:czq 1 /* basic header */ 2 #include <bits/stdc++.h> 3 /* defi ...
分类:其他好文   时间:2020-02-19 19:24:27    阅读次数:258
UFBA Practice Session for Brazilian ICPC Regionals 2018
差两题AK。 题目链接:https://codeforces.com/gym/101962 B: solver:czq 1 /* basic header */ 2 #include <bits/stdc++.h> 3 /* define */ 4 #define ll long long 5 #d ...
分类:其他好文   时间:2020-02-19 18:51:25    阅读次数:112
Codeforces 101482F(gym)随机数
给出n个点,求是否存在一条直线,使得落在直线上的点占所有点的p%以上。 n<=100000 2<=p<=100 #include<iostream> #include<cstdio> #include<cstring> #include<ctime> #include<cstdlib> #defin ...
分类:其他好文   时间:2020-02-12 00:56:34    阅读次数:75
Gym 101933 King's Colors
"Link" 设用$k$种颜色给$n$个点的树染色(必须全用)的方案数为$f(k)$,用$k$种颜色给$n$个点的树染色(可以缺用)的方案数为$g(k)$。 显然有$g(k)=k(k 1)^{n 1}=\sum\limits_{i=2}^k{k\choose i}f(i)$,直接二项式反演即可。 ...
分类:其他好文   时间:2020-01-29 12:06:25    阅读次数:55
996条   上一页 1 ... 3 4 5 6 7 ... 100 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!