[contest 782] 9.7】的更多相关文章

[contest 782] 9.7 - XJOI 个人觉得温暖题啊,,,可是卡毛空间呀!!! T1 传送…
C. Andryusha and Colored Balloons time limit per test:2 seconds memory limit per test:256 megabytes input:standard input output:standard output Andryusha goes through a park each day. The squares and paths between them look boring to Andryusha, so he…
http://codeforces.com/contest/782/problem/E 题目大意: 有n个节点,m条边,k个人,k个人中每个人都可以从任意起点开始走(2*n)/k步,且这个步数是向上取整的.要求:着k个人要走完所有的节点,且每个人至少走1步. 思路:= =dfs找一棵树,一棵树是n-1条边,所以从树根开始走完所有的,也就只有n*2-2步,所以不会达到上限.md这么简单都没有想到,233 //看看会不会爆int!数组会不会少了一维! //取物问题一定要小心先手胜利的条件 #incl…
http://codeforces.com/contest/782/problem/D 题意: 每个队有两种队名,问有没有满足以下两个条件的命名方法: ①任意两个队的名字不相同. ②若某个队 A 选用了第二种队名,那么如果队 B 的第一种队名和队 A 的相同,那么同样不能选择.当然,队B的第二个队名无所谓 思路: 学习了2-sat发现这题这么简单= =. 如果那天A了这题就前200了 //看看会不会爆int!数组会不会少了一维! //取物问题一定要小心先手胜利的条件 #include <bits…
地址:http://codeforces.com/contest/782/problem/E 题目: E. Underground Lab time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output The evil Bumbershoot corporation produces clones for gruesome experimen…
地址:http://codeforces.com/contest/782/problem/D 题目: D. Innokenty and a Football League time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Innokenty is a president of a new football league in B…
地址:http://codeforces.com/contest/782/problem/C 题目: C. Andryusha and Colored Balloons time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Andryusha goes through a park each day. The squares and…
地址:http://codeforces.com/contest/782/problem/B 题目: B. The Meeting Place Cannot Be Changed time limit per test 5 seconds memory limit per test 256 megabytes input standard input output standard output The main road in Bytecity is a straight line from…
地址:http://codeforces.com/contest/782/problem/A 题目: A. Andryusha and Socks time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Andryusha is an orderly boy and likes to keep things in their plac…
[题目链接]:http://codeforces.com/contest/782/problem/C [题意] 给你一棵树 让你满足要求 ->任意相连的3个节点的颜色不能相同 的情况下进行染色 问最少需要的颜色数目 [题解] 这种染色题一般只要贪心染就好了 即之前没出现过的颜色最小的颜色就好; (这里的之前指的是当前枚举的节点和它的父亲节点以及这个节点的儿子节点们..) 感觉很多题都要顺着题意去做啊; [完整代码] #include <bits/stdc++.h> using names…