题目:http://icpc.ahu.edu.cn/OJ/Problem.aspx?id=448这题刚开始想弄个2^16 的集合搞,然后位运算搞下。
位运算一直没搞好,不用又超时。 还是直接搜吧,加剪枝就过了。#include #include #include #include #include ...
分类:
其他好文 时间:
2014-06-10 08:47:28
阅读次数:
180
一道水题但是我错了好惨罚时罚到最后一名Problem DescriptionTime
flies, four years passed, colleage is over. When I am about to leave, a xuemei
ask me an ACM problem, but I...
分类:
其他好文 时间:
2014-06-09 20:53:59
阅读次数:
287
关于数据结构与算法讲解的书籍很多,但是用python语言去实现的不是很多,最近有幸看到一本这样的书籍,由Brad Miller and David
Ranum编写的《Problem Solving with Algorithms and Data Structures Using Python》.....
分类:
编程语言 时间:
2014-06-09 16:16:53
阅读次数:
276
http://poj.org/problem?id=1095先求出n个节点数的二叉树的形态有多少种。卡特兰数f[n]=f[n-1]*(4*n-2)/(n+1);再递归求。
1 #include 2 #include 3 #include 4 #define ll long long 5 #de...
分类:
其他好文 时间:
2014-06-09 15:14:11
阅读次数:
167
These code is for the problem "Let the balloons
Fly" in ACM 1004 which need deal with string.It is a little difficult in some
content so that I rewrit...
分类:
其他好文 时间:
2014-06-09 13:33:35
阅读次数:
266
感谢微信平台: 一天一道算法题-----每天多一点进步——-好吧 这题 我看了它的分析
还是感觉很不清晰 自己的思路 闪过 逆序数 但也不行,,,把题目 先放上来problem:列出一个 1~n 的排列
可以通过一系列的交换得到(1,2,3……n)比如,{2,1,4,3}需要两次交换(1和2 3和4...
分类:
其他好文 时间:
2014-06-08 22:33:06
阅读次数:
250
http://acm.timus.ru/problem.aspx?space=1&num=1936F
- RoshamboTime Limit:1000MS Memory Limit:65536KB 64bit IO Format:%I64d &
%I64uSubmit Status...
分类:
其他好文 时间:
2014-06-08 22:28:26
阅读次数:
300
http://acm.timus.ru/problem.aspx?space=1&num=1932B
- The Secret of IdentifierTime Limit:1000MS Memory Limit:65536KB 64bit IO
Format:%I64d & %I...
分类:
其他好文 时间:
2014-06-08 22:15:33
阅读次数:
476
A simple problemAccepted : 30Submit : 303Time
Limit : 15000 MSMemory Limit : 655360 KBProblem DescriptionThere is a simple
problem. Given a number N. ...
分类:
其他好文 时间:
2014-06-08 21:14:04
阅读次数:
226
A Simple Math ProblemTime Limit: 3000/1000 MS
(Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s):
2441Accepted Submission(s): 1...
分类:
其他好文 时间:
2014-06-08 20:33:48
阅读次数:
175