码迷,mamicode.com
首页 >  
搜索关键字:return    ( 60766个结果
POJ 2485(Kruskal算法)
第一道Kruskal算法题#include #include #include using namespace std;#define max 505int f[max],maxw;struct edge{ int st,en,w;}ed[max*max/2];int find(int k){ if...
分类:其他好文   时间:2014-07-28 15:39:43    阅读次数:181
从LLVM源码学C++(二)
在看Clang源码的过程中遇到过,返回const引用,于是就去google 了一下返回值以及参数传递等相关的知识。首先,为什么要(const 引用)的返回值?首先&的引用作用是C++独有的特性。其作用相当于传入参数时不经过拷贝,而是实实在在的传入。fun(int &a)。如果在函数内部修改了a的值,...
分类:编程语言   时间:2014-07-28 15:39:03    阅读次数:251
datagrid行中添加图片按钮
columns: [[{ field: 'id', title: '删除', width: 30, formatter: function (value,row,index) { var d = ''; ...
分类:其他好文   时间:2014-07-28 15:11:43    阅读次数:198
json对象转换为字符串
function obj2str(o) { var r = []; if (typeof o == "string") return "\"" + o.replace(/([\'\"\\])/g, "\\$1").replace(/(\n)/g, "\\...
分类:Web程序   时间:2014-07-28 15:09:03    阅读次数:217
LeetCode "Clone Graph"
A BFS usage.class Solution {public: UndirectedGraphNode *cloneGraph(UndirectedGraphNode *node) { if (!node) return NULL; UndirectedGr...
分类:其他好文   时间:2014-07-28 15:07:53    阅读次数:266
js正则 转载
script中使用的正则表达式的例子,但是没有说这些正则表达式如何使用,现在给大家几个例子,大家可以看看。利用正则表达式判断是否是0-9的阿拉伯数字function regIsDigit(fData){ var reg = new RegExp("^[0-9]$"); return (reg.t.....
分类:Web程序   时间:2014-07-28 14:43:43    阅读次数:231
hdoj 1251 字典树
代码:#include #define MAX 26 typedef struct TrieNode{ int nCount; struct TrieNode *next[MAX];}TrieNode;TrieNode Memory[1000000];int allocp = 0;TrieNode ...
分类:其他好文   时间:2014-07-28 14:42:43    阅读次数:176
js 正则 中文验证
加了一个验证中文的函数如下:function isChn(str){ var reg = /^[u4E00-u9FA5]+$/; if(!reg.test(str)){ return false; } return true;}
分类:Web程序   时间:2014-07-28 14:40:53    阅读次数:274
c++ string的size()函数和length()函数
C++标准库中的string中两者的源代码如下: size_type __CLR_OR_THIS_CALL length() const { // return length of sequence return (_Mysize); } size_type __...
分类:编程语言   时间:2014-07-28 13:45:40    阅读次数:306
【145】.NET Framework类库索引
C#编程基础:A1 ………… 基础A2 ………… using 关键字A3 ………… as 关键字A4 ………… is 关键字A5 ………… switch 关键字A6 ………… return 语句关键字A7 …………enum 关键字A8 …………Enum 类A9 …………Struct 类型G1 ………...
分类:Web程序   时间:2014-07-28 13:44:41    阅读次数:257
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!