System V 共享内存信息结构struct shmid_ds { struct ipc_perm
shm_perm; // operation permission struct size_t shm_segsz; // segment size pid_t
shm_lpid;...
分类:
其他好文 时间:
2014-06-03 11:20:18
阅读次数:
264
是什么影响你程序的性能?
编写程序时,也许你不经意间,就不知不觉的定义了错误的类型,从而发生了额外的性能消耗,从而降低了效率,不要说就发生那么一次两次,如果说是程序中发生了循环、网络程序(不断请求处理的)等这些时候,减少了不必要额外的消耗,使优化程序提高效率的一种途径。不仅跬步,无以至千里,不积小...
分类:
其他好文 时间:
2014-06-03 08:08:39
阅读次数:
204
BFS+优先级队列。 1 #include 2 #include 3 #include 4
#include 5 using namespace std; 6 7 #define MAXNUM 205 8 9 typedef struct
node_st {10 int x, y...
分类:
其他好文 时间:
2014-06-03 06:50:09
阅读次数:
259
BMP文件由位图文件头、位图信息头、调色板和图像数据四部分组成(1)位图文件头1 typedef
struct tagBITMAPFILEHEADER2 {3 WORD bfType; //位图文件的类型,必须为BM(1-2字节)4 DWORD b...
分类:
其他好文 时间:
2014-05-31 12:54:56
阅读次数:
254
/src/graphlab-master/deps/local/include/boost/atomic/atomic.hpp:166:16:
error: ‘uintptr_t’ was not declared in this scope typedef atomic
atomic_uintpt...
分类:
其他好文 时间:
2014-05-31 11:53:03
阅读次数:
345
一棵普通树,树中的结点没有指向父节点的指针,求一棵普通树的两个结点的最低公共祖先。代码如下,我太懒没有加注释,大家自己看吧! 1 #include 2
#include 3 #include 4 using namespace std; 5 6 struct TreeNode /...
分类:
其他好文 时间:
2014-05-31 08:08:32
阅读次数:
262
题目:http://poj.org/problem?id=1056题意:判断是否有串是其他串的前缀#include#include#include#include#include#include#include#includeusing
namespace std;struct Node{ i...
分类:
其他好文 时间:
2014-05-31 07:46:48
阅读次数:
227
Sort a linked list inO(nlogn) time using
constant space complexity./** * Definition for singly-linked list. * struct
ListNode { * int val; * L...
分类:
其他好文 时间:
2014-05-30 15:17:18
阅读次数:
312
Sort a linked list using insertion sort./** *
Definition for singly-linked list. * struct ListNode { * int val; * ListNode
*next; * ListNo...
分类:
其他好文 时间:
2014-05-30 15:14:27
阅读次数:
245
Given an array where elements are sorted in
ascending order, convert it to a height balanced BST./** * Definition for binary
tree * struct TreeNode { ...
分类:
其他好文 时间:
2014-05-30 15:10:23
阅读次数:
227