in_interrupt()是判断当前进程是否处于中断上下文,这个中断上下文包括底半部和硬件中断处理过程,函数实现:#define in_interrupt() ({ const int __cpu = smp_processor_id(); / (local_irq_count(__cpu) + ...
分类:
其他好文 时间:
2014-09-09 17:51:09
阅读次数:
180
execute相信大家都用的用熟了,简写为exec,除了用来执行存储过程,一般都用来执行动态Sql sp_executesql,sql2005中引入的新的系统存储过程,也是用来处理动态sql的, 如: exec sp_executesql @sql, N'@count int out,@id va....
分类:
数据库 时间:
2014-09-09 17:34:59
阅读次数:
285
//给出的字符串在模式串中出现几次# include # include
# include
# include
using namespace std;
# define MAX 26
typedef struct Trie_Node
{
int count;//记录包含该结点的单词个数
int id;//最后一次经过此结点的商品的id
Trie_Node *nex...
分类:
其他好文 时间:
2014-09-09 16:14:48
阅读次数:
126
--判断表是否存在,如果存在则删除declare num number; begin select count(1) into num from all_tables where TABLE_NAME = 'EMP' and OWNER='SCOTT'; if...
分类:
数据库 时间:
2014-09-09 15:45:38
阅读次数:
254
sar可用于监控Linux系统性能,帮助我们分析性能瓶颈。sar工具的使用方式为”sar [选项] intervar [count]”,其中interval为统计信息采样时间,count为采样次数。
下文将说明如何使用sar获取以下性能分析数据:
整体CPU使用统计各个CPU使用统计内存使用情况统计整体I/O情况各个I/O设备情况网络统计
整体CPU使用统计(...
分类:
其他好文 时间:
2014-09-09 13:24:08
阅读次数:
253
2014-08-0416:33:57(1) map map定义形式 map map_name; map的基本操作函数:C++ Maps是一种关联式容器,包含“关键字/值”对 begin() 返回指向map头部的迭代器 clear() 删除所有元素 count() 返回指定元素出现的次数 e...
分类:
编程语言 时间:
2014-09-09 11:40:28
阅读次数:
239
Strings>>> s = 'django is cool'>>> words = s.split()>>> words['django', 'is', 'cool']>>> ' '.join(words)'django is cool'>>> s.count('o')3>>> s.find('g...
分类:
编程语言 时间:
2014-09-09 11:27:48
阅读次数:
224
0.两者比较: memmove用于从src拷贝count个字符到dest,如果目标区域和源区域有重叠的话,memmove能够保证源串在被覆盖之前将重叠区域的字节拷贝到目标区域中。但复制后src内容会被更改。但是当目标区域与源区域没有重叠则和memcpy函数功能相同。 memmove在copy两个.....
分类:
编程语言 时间:
2014-09-09 11:26:48
阅读次数:
286
import java.util.Scanner;public class Main { private static int count=0; public static void mergesort(int a[],int low,int high) { if(l...
分类:
编程语言 时间:
2014-09-09 10:39:58
阅读次数:
241
Best Time to Buy and Sell Stock
Say you have an array for which the ith element is the price of a given stock on day i.
If you were only permitted to complete at most one transaction (ie,...
分类:
其他好文 时间:
2014-09-08 09:39:06
阅读次数:
312