centos5.8,g++4.1.2最近操作比较多,小小笔记下静态库,动态库编译和链接//1.DynamicMath.hclass DynamicMath{ public: static double add(double a, double b); static double sub(double...
分类:
其他好文 时间:
2015-08-03 20:45:21
阅读次数:
92
sub sum_of_fred_and_barney{ print "Hey,you called the sum_of_fred_and_barney subroutine!\n"; $fred+$barney;}$fred =3;$barney=4;$wilma =&sum_of_...
分类:
其他好文 时间:
2015-08-03 13:00:13
阅读次数:
139
慢慢积累 先来排序 快速排序使用分治法(Divide?and?conquer)策略来把一个串行(list)分为两个子串行(sub-lists)。 算法步骤: 1?从数列中挑出一个元素,称为?“基准”(pivot), 2?重新排序数列,所有...
分类:
编程语言 时间:
2015-08-02 21:47:31
阅读次数:
259
比如你用local在栈上定义了一个局部变量LocalVar,你知道实际的指令是什么么?一般都差不多像下面的样子: push ebp mov esp, ebp sub esp, 4 现在栈上就有了4各字节的空间,这就是你的局部变量。 接下来,你执行mov LocalVar, 4...
分类:
其他好文 时间:
2015-08-02 06:18:27
阅读次数:
215
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=5335
题面:
Walk Out
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)
Total Submission(s): 2355 Accepted Sub...
分类:
其他好文 时间:
2015-08-01 14:20:39
阅读次数:
251
#coding:utf-8#author:Blood_Zeroimport retmp_list=[]f=open("E:/ASP.txt","r")f1=f.readlines()for i in f1: rule=re.compile('\W') i=re.sub(rule,'',i...
分类:
编程语言 时间:
2015-08-01 12:53:03
阅读次数:
148
#include
using namespace std;
const int maxn = 1000000 + 10;
int T,n,m,k,Case = 0,a[maxn],cnt[maxn];
map p;
vector g[105];
int main() {
scanf("%d",&T);
while(T--) {
scanf("%d%d%d",&n,&...
分类:
其他好文 时间:
2015-08-01 10:07:38
阅读次数:
118
一、 发布订阅消息
发布订阅(pub/Sub)是一种消息通信模式,主要的目的是解除消息发布者和消订阅者之间的耦合,Redis作为一个pub/sub的server,在订阅者和发布者之间起到了消息路由的功能。订阅者可以通过subscribe和psubscribe命令向Redis Server订阅自己感兴趣的消息类型,Redis将信息类型称为通道(channel).当发布者通过publish...
分类:
其他好文 时间:
2015-07-31 18:20:56
阅读次数:
108
字符串中子串的查找// 字符串中子串的查找.cpp : 定义控制台应用程序的入口点。
//#include "stdafx.h"
#include
#includeconst char *strstr(const char* src,const char* sub)
{
const char* bp;
const char* sp; if(...
分类:
其他好文 时间:
2015-07-31 18:20:13
阅读次数:
111
一、下载SVN插件subclipse下载地址:http://subclipse.tigris.org/servlets/ProjectDocumentList?folderID=2240网盘下载:http://yunpan.cn/cdgu6QKmSR57P 访问密码 c137在打开的网站中找到sub...
分类:
系统相关 时间:
2015-07-31 17:56:05
阅读次数:
172