上一页 1 2 3 4 5 6 7 8 9 10 ··· 16 下一页
摘要: http://blog.csdn.net/ysuncn/article/details/1788187 阅读全文
posted @ 2016-02-25 21:04 伟大的臭猪猪 阅读(190) 评论(0) 推荐(0)
摘要: 下面是个关于递归调用简单但是很能说明问题的例子: [cpp] view plain copy /*递归例子*/ #include<stdio.h> void up_and_down(int); int main(void) { up_and_down(1); return 0; } void up_ 阅读全文
posted @ 2016-02-25 13:40 伟大的臭猪猪 阅读(555) 评论(0) 推荐(0)
摘要: 【转】http://lavasoft.blog.51cto.com/62575/181781/在集合操作中,常常离不开对集合的遍历,对集合遍历一般来说一个foreach就搞定了,但是,对于Stack、Queue、Map类型的遍历,还是有一些讲究的。最近看了一些代码,在便利Map时候,惨不忍睹,还有一... 阅读全文
posted @ 2016-01-12 17:20 伟大的臭猪猪 阅读(384) 评论(0) 推荐(0)
摘要: String 常用方法: 获取长度:int length = strl.length() 获取第i个字符:char iChar = str.charAt(i) String转成字符数组:char[] charArr = str.toCharArray(); String排序(要先变成字符数组才能排序 阅读全文
posted @ 2016-01-09 20:12 伟大的臭猪猪 阅读(469) 评论(0) 推荐(0)
摘要: 位运算可以大大减小算法空间复杂度,提高效率,很巧妙!先说一下位运算的简单用法1. 按位与 &用途:清零,取一个数中的某些指定位,保留一个数中的某些指定位2. 按位或 |用途:将一个数的某些位指定为13. 按位异或 ^用途:交换两个数a=a^b; b=a^b; a=a^b让我们看看这三条语句执行后的结... 阅读全文
posted @ 2016-01-08 11:28 伟大的臭猪猪 阅读(362) 评论(0) 推荐(0)
摘要: 1、java 设计模式:http://blog.csdn.net/JAVE_LOVER/article/category/23797032、Java web框架的思考:http://www.oschina.net/question/12_52027?fromerr=NEknevKe3、下载的英文课件 阅读全文
posted @ 2015-12-21 20:46 伟大的臭猪猪 阅读(188) 评论(0) 推荐(0)
摘要: 1、Ycbcr RGB空间转换 :http://www.cnblogs.com/Imageshop/archive/2013/02/14/2911309.html2、抠图:http://www.cnblogs.com/Imageshop/p/3550185.html3、cv代码:http://blo... 阅读全文
posted @ 2015-12-21 20:37 伟大的臭猪猪 阅读(167) 评论(0) 推荐(0)
该文被密码保护。 阅读全文
posted @ 2015-12-19 22:05 伟大的臭猪猪 阅读(9) 评论(0) 推荐(0)
摘要: Given an integer n, return the number of trailing zeroes in n!.Note: Your solution should be in polynomial time complexity.题目大意:给定一个整数n,返回n!(n的阶乘)数字中的... 阅读全文
posted @ 2015-12-17 16:53 伟大的臭猪猪 阅读(556) 评论(0) 推荐(0)
摘要: GivennumRows, generate the firstnumRowsof Pascal's triangle.For example, givennumRows= 5,Return[ [1], [1,1], [1,2,1], [1,3,3,1], [1,4,6,4,1]... 阅读全文
posted @ 2015-12-17 16:02 伟大的臭猪猪 阅读(277) 评论(0) 推荐(0)
摘要: Link:http://www.cnblogs.com/Gavin_Liu/archive/2011/04/13/2011214.htmlKeywords: Dynamic Programming; Recursive Methods[为什么写这类文章]漫谈算法(零)序[这系列文章里会用到的一下符号... 阅读全文
posted @ 2015-12-17 11:12 伟大的臭猪猪 阅读(297) 评论(0) 推荐(0)
摘要: Given a non-negative number represented as an array of digits, plus one to the number.The digits are stored such that the most significant digit is at... 阅读全文
posted @ 2015-12-17 11:11 伟大的臭猪猪 阅读(180) 评论(0) 推荐(0)
摘要: 二叉树本身固有的递归性质,通常可以用递归算法解决,虽然递归代码简介,但是性能不如非递归算法。常用的操作是构建二叉树、遍历二叉树(先序、中序、后序、都属于DFS深度优先搜索算法,使用栈来实现),广度优先BFS使用队列来遍历。参考博客:链表、二叉树操作、深度优先、广度优先的算法注意:这个图里面虚点框代表... 阅读全文
posted @ 2015-12-13 22:40 伟大的臭猪猪 阅读(523) 评论(0) 推荐(0)
摘要: 本文总结了Java程序员常犯的10个错误。#1. 把Array转化成ArrayList把Array转化成ArrayList,程序员经常用以下方法:List list = Arrays.asList(arr);Arrays.asList() 实际上返回一个ArrayList,但是这个ArrayList... 阅读全文
posted @ 2015-12-13 22:34 伟大的臭猪猪 阅读(412) 评论(1) 推荐(0)
摘要: 【Balanced Binary Tree】Given a binary tree, determine if it is height-balanced.For this problem, a height-balanced binary tree is defined as a binary t... 阅读全文
posted @ 2015-12-05 21:30 伟大的臭猪猪 阅读(237) 评论(0) 推荐(0)
上一页 1 2 3 4 5 6 7 8 9 10 ··· 16 下一页