摘要:311. Ice-cream TycoonTime limit per test: 0.5 second(s)Memory limit: 65536 kilobytesinput: standardoutput: standardYou've recently started an ice-crea...
阅读全文
摘要:319. Kalevich Strikes BackTime limit per test: 0.5 second(s)Memory limit: 65536 kilobytesinput: standardoutput: standardAnd yet again the Berland comm...
阅读全文
摘要:104. Little shop of flowerstime limit per test: 0.25 sec.memory limit per test: 4096 KBPROBLEMYou want to arrange the window of your flower shop in a most pleasant way. You haveFbunches of flowers, each being of a different kind, and at least as many vases ordered in a row. The vases are glued onto
阅读全文
摘要:101. Dominotime limit per test: 0.25 sec.memory limit per test: 4096 KBDominoes – game played with small, rectangular blocks of wood or other material, each identified by a number of dots, or pips, on its face. The blocks usually are called bones, dominoes, or pieces and sometimes men, stones, or ev
阅读全文
摘要:题目链接:http://acm.sgu.ru/problem.php?contest=0&problem=275题意:给你n个数,可以选择任意个数异或,但是要使得最后的异或值最大。我们把每个数用二进制表示,要使得最后的异或值最大,就是要让高位尽量为1,高位能不能为1就必须用高斯消元判断了。1. 根据数的二进制表示,建立方程组的矩阵,结果那列置为1。2. 从下往上高斯消元(高位放下面),如果该行有未被控制的变元,则该行的结果一定为1,且该变元控制该行。3. 从该行往上依次消掉(异或)该变元。4. 如果该行没有可以用来控制的变元,如果最后一列是0,则该行结果也为1,否则该行结果为0。这里能
阅读全文
摘要:题目链接:http://acm.sgu.ru/problem.php?contest=0&problem=200200. Cracking RSAtime limit per test: 0.25 sec.memory limit per test: 65536 KBinput: standardoutput: standardThe following problem is somehow related to the final stage of many famous integer factorization algorithms involved in some crypto
阅读全文