码迷,mamicode.com
首页 >  
搜索关键字:empty    ( 6963个结果
dedecms搜索提示"关键字不能小于2个字节!"
在测试自己制作的搜索页模板时,如果遇到搜索时提示"关键字不能小于2个字节!"!打开plus/search.php把if(($keyword=='' || strlen($keyword)<2) && empty($typeid)){ ShowMsg('关键字不能小于2个字节!','-1'); exi...
分类:其他好文   时间:2015-04-04 15:12:22    阅读次数:102
获取真实ip
function getAddr(){ if (!empty($_SERVER['HTTP_CLIENT_IP'])) { $ip=$_SERVER['HTTP_CLIENT_IP']; } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) { $i...
分类:其他好文   时间:2015-04-03 23:38:52    阅读次数:157
Guid 使用记录
Guid 使用记录; Guid 数据不能设为null 用 00000000-0000-0000-0000-000000000000 代替默认值。实体新建时,可以赋值为 Guid.Empty 也就是 00000000-0000-0000-0000-000000000000 Gui...
分类:其他好文   时间:2015-04-03 16:50:28    阅读次数:107
剑指offer统计字符数组中第一次出现的字符
给定一个字符串,例如“abaccdeff”则第一次出现的字符就是b; #include #include using namespace std; void first(const string &input) { if(input.empty()) return ; string::size_type length=input.size(); int *times=new int[l...
分类:编程语言   时间:2015-04-03 13:34:49    阅读次数:136
House Robber(动态规划)
思路:代码:class Solution {public: int rob(vector &num) { if(num.empty()) return 0; int size=num.size(); if(size==1) return num[0];...
分类:其他好文   时间:2015-04-03 12:47:12    阅读次数:112
Unique Paths II - LeetCode
Unique Paths II - LeetCode 题目: Follow up for "Unique Paths": Now consider if some obstacles are added to the grids. How many unique paths would there be? An obstacle and empty space is mar...
分类:其他好文   时间:2015-04-03 09:32:22    阅读次数:105
php isset( $test ) 的神奇之处。
很久一段时间没更新博客了,由于近段时间一直在忙 挑战杯 的项目,所以没怎样把一些总结放上来。这次,总结下 php 的一个 函数 :boolean isset($test),返回值:boolean类型,传入参数不为空,返回true,反之,false参数:常用一个 $ 变量该函数和empty 差不多,用...
分类:Web程序   时间:2015-04-02 20:52:48    阅读次数:148
leetcode:Binary Tree Postorder Traversal
class Solution { public: vector postorderTraversal(TreeNode *root) { vector res; stack>s; TreeNode *p = root; while(p!=NULL||!s.empty()) { while...
分类:其他好文   时间:2015-04-02 19:02:48    阅读次数:117
leetcode:Binary Tree Preorder Traversal
class Solution { public: vector preorderTraversal(TreeNode *root) { vector res; stack s; TreeNode * p = root; while(p!=NULL||!s.empty()) { while...
分类:其他好文   时间:2015-04-02 19:02:38    阅读次数:131
leetcode:Binary Tree Inorder Traversal
class Solution { public: vector inorderTraversal(TreeNode *root) { vector res; stack s; TreeNode * p = root; while(p!=NULL||!s.empty()) { while(...
分类:其他好文   时间:2015-04-02 19:01:33    阅读次数:98
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!