【题目】
原文:
1.3 Design an algorithm and write code to remove the duplicate characters in a string without using any additional buffer. NOTE: One or two additional variables are fine. An
extra copy of...
分类:
其他好文 时间:
2014-05-07 08:48:12
阅读次数:
372
目的:科研中,需要分析在每次迭代过程中参与计算的顶点数目,来进一步优化系统。比如,在SSSP的compute()方法最后一行,都会把当前顶点voteToHalt,即变为InActive状态。所以每次迭代完成后,所有顶点都是InActive状态。在大同步后,收到消息的顶点会被激活,变为Active状态,然后调用顶点的compute()方法。本文的目的就是统计每次迭代过程中,参与计算的顶点数目。下面附上SSSP的compute()方法:...
分类:
其他好文 时间:
2014-05-07 06:25:52
阅读次数:
415
题目链接:http://poj.org/problem?id=1011
这道题用到了深搜+剪枝。
#include
#include
#include
using namespace std;
int a[65];
int vis[65];
int n;
int cmp(int x,int y)
{
return x>y;
}
int dfs(int len,int need,int ...
分类:
其他好文 时间:
2014-05-05 13:28:57
阅读次数:
290
ACM 博弈 Good Luck in CET-4 Everybody! hdu1847 规律...
分类:
其他好文 时间:
2014-05-05 13:20:41
阅读次数:
359
主要功能:实现 网页离线加载。基本思想来源于AFCache。作者是Rob
Napier(IOSX Programming的作者)。使用方法:To build, you will need the Reachability code
from Apple (included). That requir...
分类:
其他好文 时间:
2014-05-04 20:32:05
阅读次数:
1699
最近,一个朋友拿到了一个制造业企业的信息部经理的offer,负责公司信息部门的组建及帮助公司实现信息化。这家公司有2000人左右,已有局域网但基本没实现信息化。一直以来都在软件公司任产品和项目经理的他一时不知从那入手而请教于我。对此作为一个从事企业信息化工作十几年的IT人员,我还是有一些看法的,今....
分类:
其他好文 时间:
2014-05-04 20:11:56
阅读次数:
439
剑指offer上的第一道题目,在九度OJ上测试通过
题目描述:
在一个二维数组中,每一行都按照从左到右递增的顺序排序,每一列都按照从上到下递增的顺序排序。请完成一个函数,输入这样的一个二维数组和一个整数,判断数组中是否含有该整数。
输入:
输入可能包含多个测试样例,对于每个测试案例,
输入的第一行为两个整数m和n(1<=m,n<=1000):代表将要输入的矩阵的行数和列数。
输入的第二行包括一个整数t(1<=t<=1000000):代表要查找的数字。
接下来的m行,每行有n个数,代表题目所给出的m行n列的矩...
分类:
其他好文 时间:
2014-05-04 18:26:36
阅读次数:
348
【题目】
B
Age Sort
Input: Standard Input
Output: Standard Output
You are given the ages (in years) of all people of a country with at least 1 year of age. You kn...
分类:
其他好文 时间:
2014-05-03 16:51:42
阅读次数:
427
【题目】
Problem C
CALCULATOR CONUNDRUM
Alice got a hold of an old calculator that can display n digits. She was bored enough to come up with the following time waster.
She enters a number k t...
分类:
其他好文 时间:
2014-05-03 15:37:03
阅读次数:
308