随笔分类 - codeforce
摘要:题目链接:Codeforces Round #367 (Div. 2) D. Vasiliy's Multiset 题意: 给你一些操作,往一个集合插入和删除一些数,然后?x让你找出与x异或后的最大值 题解: trie树xjb搞就行,每次要贪心,尽量满足高位为1. 1 #include<bits/s
阅读全文
摘要:题目链接:Codeforces Round #367 (Div. 2) C. Hard problem 题意: 给你一些字符串,字符串可以倒置,如果要倒置,就会消耗vi的能量,问你花最少的能量将这些字符串排成字典序 题解: 当时1点过头太晕了,看错题了,然后感觉全世界都会,就我不会,- -!结果就是
阅读全文
摘要:B. Spider Man time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output B. Spider Man time limit p
阅读全文
摘要:C. Thor time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output C. Thor time limit per test 2 se
阅读全文
摘要:D. Road to Post Office time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output D. Road to Post Of
阅读全文
摘要:B. Powers of Two time limit per test 3 seconds memory limit per test 256 megabytes input standard input output standard output B. Powers of Two time l
阅读全文
摘要:C. Cellular Network time limit per test 3 seconds memory limit per test 256 megabytes input standard input output standard output You are given n poin
阅读全文
摘要:E. Connecting Universities time limit per test 3 seconds memory limit per test 256 megabytes input standard input output standard output E. Connecting
阅读全文
摘要:C. They Are Everywhere time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output C. They Are Every
阅读全文
摘要:D. As Fast As Possible time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output On vacations n pup
阅读全文
摘要:D. Fix a Tree time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output D. Fix a Tree time limit p
阅读全文
摘要:B. One Bomb time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output You are given a description o
阅读全文
摘要:C. Vacations time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output C. Vacations time limit per
阅读全文
摘要:题目连接:http://codeforces.com/contest/688/problem/C 题意:给你一些边,问你能否构成一个二分图 题解:二分图:二分图又称作二部图,是图论中的一种特殊模型。 设G=(V,E)是一个无向图,如果顶点V可分割为两个互不相交的子集(A,B),并且图中的每条边(i,
阅读全文
摘要:题目连接:http://codeforces.com/contest/676/problem/B 题意:给你一个N层的杯子堆成的金字塔,倒k个杯子的酒,问倒完后有多少个杯子的酒是满的 题解:由于数据不是很大,直接模拟就行了 1 #include<cstdio> 2 #include<cstring>
阅读全文
摘要:题目连接:http://codeforces.com/contest/676/problem/C 题意:一串字符串,最多改变k次,求最大的相同子串 题解:很明显直接尺取法 1 #include<cstdio> 2 #include<cstring> 3 #include<cmath> 4 #incl
阅读全文
摘要:D2. Magic Powder - 2 time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output The term of this pro
阅读全文

浙公网安备 33010602011771号