随笔分类 -  UVa

摘要:Problem BPeter’s SmokesInput:standard inputOutput:standard outputTime Limit:4 secondsMemory Limit:32 MBPeter hasncigarettes. He smokes them one by one keeping all the butts. Out ofk> 1butts he can roll a new cigarette.How many cigarettes can Peter have?InputInput is a sequence of lines. Each line 阅读全文
posted @ 2013-02-25 16:14 三人木君 阅读(311) 评论(0) 推荐(0)
摘要:Power of CryptographyBackgroundCurrent work in cryptography involves (among other things) large prime numbers and computing powers of numbers modulo functions of these primes. Work in this area has resulted in the practical use of results from number theory and other branches of mathematics once con 阅读全文
posted @ 2013-02-20 17:42 三人木君 阅读(688) 评论(0) 推荐(0)
摘要:100 - The 3n + 1 problemTime limit: 3.000 secondsThe 3n + 1 problemBackgroundProblems in Computer Science are often classified as belonging to a certain class of problems (e.g., NP, Unsolvable, Recursive). In this problem you will be analyzing a property of an algorithm whose classification is not k 阅读全文
posted @ 2013-02-02 14:18 三人木君 阅读(1968) 评论(0) 推荐(0)