POSIX共享内存不需要自己手动挂载,只要打开成功,就会自动挂载.一般挂载在 /dev/shm 目录下
cd /dev/shm
od -c xyz
1. shm_open 函数
功能:用来创建或打开一个共享内存对象
原型:
int shm_open(const char* name,int oflag,mode_t mode);
参数:
name:共享内存...
分类:
其他好文 时间:
2015-06-06 12:09:35
阅读次数:
265
http://blog.csdn.net/g1342522389/article/details/46272473
一定要赞,小编很辛苦。...
分类:
其他好文 时间:
2015-06-06 12:08:17
阅读次数:
93
package cn.ds;
import java.io.BufferedOutputStream;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStream...
分类:
其他好文 时间:
2015-06-06 12:10:21
阅读次数:
161
外观模式:
为子系统中的一系列接口提供了一个统一的界面。外观模式定义了一个高层次的接口以使子系统更加容易使用。Provide a unified interface to a set of interfaces in a subsystem.
Façade defines a higher-level interface that makes the subsystem easier to us...
分类:
其他好文 时间:
2015-06-06 12:10:53
阅读次数:
265
2,添加信息投诉和修改投诉信息模块
关于投诉信息的添加模块和修改模块均使用的是一个窗体,其其区别是根据向窗体中所传递的参数来实现的,这个模块的投诉主题,投诉客户和投诉内容是必填项,当添加时,投诉其主要功能就是向CustomerManagement数据库的inform数据表中插入服务的基本信息;当更改投诉信息时,其主要的功能就是更改CustomerManagement数据库中的in...
分类:
其他好文 时间:
2015-06-06 12:09:31
阅读次数:
211
Description
Every year, Farmer John's N (1 <= N <= 20,000) cows attend "MooFest",a social gathering of cows from around the world. MooFest involves a variety of events including haybale stacking, f...
分类:
其他好文 时间:
2015-06-06 12:09:17
阅读次数:
147
题目描述
Given a binary tree and a sum, find all root-to-leaf paths where each path’s sum equals the given sum.
For example:
Given the below binary tree and sum = 22, 5
/ \...
分类:
其他好文 时间:
2015-06-06 12:09:10
阅读次数:
117
Milk
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 15697 Accepted Submission(s): 3947
Problem Description
Ignatius drinks milk eve...
分类:
其他好文 时间:
2015-06-06 12:08:10
阅读次数:
156
哎,刚刚submit上paper比较心虚啊,无心学习,还是好好码码文字吧。
subgradient中文名叫次梯度,和梯度一样,完全可以多放梯度使用,至于为什么叫子梯度,是因为有一些凸函数是不可导的,没法用梯度,所以subgradient就在这里使用了。注意到,子梯度也是求解凸函数的,只是凸函数不是处处可导。f:X→Rf: \mathcal{X}\rightarrow \mathbb{R}是一个凸函...
分类:
其他好文 时间:
2015-06-06 12:06:38
阅读次数:
218
You work in a company which organizes marriages. Marriages are not that easy to be made, so, the job is quite hard for you.The job gets more difficult when people come here and give their bio-data with...
分类:
其他好文 时间:
2015-06-06 12:08:28
阅读次数:
185
http://acm.hdu.edu.cn/showproblem.php?pid=1849
简单的尼姆博弈:
代码如下:#include
#include
using namespace std;int main()
{
int m,n,t;
while(cin>>m,m)
{
int ans=0;...
分类:
其他好文 时间:
2015-06-06 12:06:38
阅读次数:
103
最近在准备复习算法设计的考试,下边记录一些,看笔记时突然想到的解法。
问题是这样的
用递归实现 n 个元素的全排列。当时老师给出的解答是 假定第i个元素 ri 放在首位,于是 f(r1,r2,…,rn) = f(ri U {r1, r2,….,rn}) = U (ri & f(r1,r2, …, rn)), 当时应该是听懂了,不过现在看到这个笔记,又醉了。 (这货居然是我上课记的笔记 。。。。...
分类:
其他好文 时间:
2015-06-06 12:05:55
阅读次数:
105
在学习三层搭框架过程中,将bug修改完后,运行的时候,会弹出一个问题,(⊙o⊙)…不能运行,调试完了也卡不到效果啊,赶紧找解决方法。。
提示语:
无法直接启动带有“类库输出类型”的项目
若要调试此项目,请在此解决方案中添加一个引用库项目的可执行项目。将这个可执行项目设置为启动项
因为很久以前就遇到过这样问题,然后我就检查解决方案的启动项是不是设置错误了。但...
分类:
其他好文 时间:
2015-06-06 12:05:56
阅读次数:
134
django 环境搭建
1. 沙盒环境。
首先不污染开发环境,作为测试使用
2.使用pip install django命令安装即可。...
分类:
其他好文 时间:
2015-06-06 12:06:13
阅读次数:
112
例题5——9 数据库 Database UVa 1592
#include
#include
#include
#include
using namespace std;
int cnt[10042][12];
int n,m;
void before()//此函数把每个格子里的字符串都映射成数字
{
int x=0;
char ch;
getchar(); // ...
分类:
其他好文 时间:
2015-06-06 12:07:09
阅读次数:
104
1 安全技术的增强,例如对称密钥算法和公钥密码算法,在金融和通信方面的发展,确实让一个匿名的互联网有了基础保证,是有益的;
2 让更多的精英把更多的精力放在安全上面,而忽视了安全本身要保护的对象,安全就不是促进社会发展了,而是反之了。
3 自然科学、生物医学、人工智能、工业设计才是王道,他们的关注点是:进步、健康、智能和美感,而安全只不过是一个篱笆。
4 一份冰激凌一定需要杯子装、盒子装,无...
分类:
其他好文 时间:
2015-06-06 12:05:52
阅读次数:
200
建造者模式:
将一个复杂对象的建造过程和它的表示分离开来,这样相同的建造过程可以创建不同的表示。Separate the construction of a complex object from its representation so that the same construction process can create different representations.通俗一点就是如...
分类:
其他好文 时间:
2015-06-06 12:05:09
阅读次数:
106