现在位置: 首页 > whistling发表的所有文章
  • 07月
  • 27日
移动开发 ⁄ 共 15313字 评论关闭
文章目录 AppRuntime分析 概述 我们都知道,Android系统存在着两个完全不同的世界: 1.      Java世界,Google提供的SDK编写出来的程序大部分都是针对这个世界的。在这个世界中运行的程序都是基于Dalvik虚拟机的java程序。 2.      Native世界,也就是用Native语言C或者C++开发的程序,例如采用NDK开发的程序。 于是便有了这个疑问: Android系统是基于linux内核构建的,那么最早肯定是native世界,可java世界是什么时候开始被创建出来的呢? 带着这个疑问,我们今天就来......
阅读全文
  • 06月
  • 09日
综合 ⁄ 共 444字 评论关闭
细细算来,自己学程序也快有一年了,其实以前只是表示了浓厚的兴趣,并没有过多深入地去研读. 归其原因:1.对自己的不自信.              2.惰性.              3.躁动的心,老是想着太多太多无谓的事,所以无法静下来. 前几天,在论坛偶然发现了一个帖子,说的就是程序员法则.有很多很多,但给我感触最深的就只这一句:                                             "不要做浮躁的人." 看到这句话,心里一下就释然了.现在知道了自己老是不能前进的原因了,原来自己的那颗心,一直是那么的躁动不安啊.... 这几天又重新拿起了程序的书,......
阅读全文
  • 01月
  • 06日
综合 ⁄ 共 5597字 评论关闭
1.Laplacian/Laplacian of Gaussian1 (LoG) As Laplace operator may detect edges as well as noise (isolated, out-of-range), it may be desirable to smooth the image first by a convolution with a Gaussian kernel of width   to suppress the noise before using Laplace for edge detection:  The first equal sign is due to the fact that  So we can obtain the Laplacian of Gaussian  first and then convolve it with the input image. To do so, first consider  and  Note that for......
阅读全文
  • 05月
  • 13日
综合 ⁄ 共 860字 评论关闭
这么好用的开源软件就不用我解释它有什么用处了吧,暂时玩了一下,把相关的信息整理一下方便后面使用,或者帮助众屌丝节省时间。现在大型的应用喜欢用分布式缓存来应对高并发,但是很抱歉告诉大家,他的服务端是不支持集群的,只能靠client端自己做一个负载均衡的策略了。1.memcached服务器端配置。官网信息简单明了: Debian/Ubuntu: apt-get install libevent-dev ;Redhat/Centos: yum install libevent-devel     wget http://memcached.org/latest     tar -zxvf memcached-1.x.x.tar.gzcd memcached-1.x.x ./configure &......
阅读全文
  • 04月
  • 21日
综合 ⁄ 共 466字 评论关闭
       位运算巧解题。题意:给你n个数,n为奇数,这n个数里面除了一个数只出现一次其他数都有出现两次,请输出那个出现一次的数。        我的解题思路:根据异或运算性质,相同的数异或等于0,0与任何数异或都得任何数,异或运算满足交换律。这么以来把这所有的数都异或之后就得到了只出现一次的数了。        我的解题代码: #include <cstdio> #include <cstdlib> #include <cstring> #include <cctype> #include <cmath> #include <climits> #include <algorithm> using names......
阅读全文
  • 04月
  • 03日
综合 ⁄ 共 3654字 评论关闭
500pt: 链接:http://codeforces.com/problemset/problem/376/A 分析:水题,模拟实现一下就行,要注意的是支点左右的和要用long long 来做,不然会错 代码: #include <vector> #include <list> #include <map> #include <set> #include <deque> #include <queue> #include <stack> #include <bitset> #include <algorithm> #include <functional> #include <numeric> #include <utility> #include <sstream> #include <iostream> #includ......
阅读全文
  • 02月
  • 08日
综合 ⁄ 共 2413字 评论关闭
上一篇文章我们理解怎样使用接口回调的方式将数据从Fragment传递到Activity中,这里我们将探讨如何将数据从Activity传到Fragment中。 思路:把数据先保存到Bundle中,然后在调用setArguments()方法进行传递。 MainActivity.java代码: public class MainActivity extends FragmentActivity { private FragmentManager manager; private FragmentTransaction transaction; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main......
阅读全文
  • 02月
  • 06日
综合 ⁄ 共 7487字 评论关闭
Game Developer Magazine 1994 - 2000年,共7年的游戏开发者杂志电子版(含源码)Graphics Programming Black Book (by Michael Abrash),图形编程黑书,Id software的Michael Abrash编著Game Programming Gems I.rar ,游戏编程精粹I、II(含源码)Game Programming Gems II.rarGraphics Gems I.rar ,图形学精粹I、II、III、IV、VGraphics Gems II.rarGraphics Gems III IBM.rarGraphics Gems IV IBM.rarGraphics Gems V.rarComputer Graphics, C Version (2nd Ed.).rar ,计算机图形学C版(第二版)half_life2_engine.rar ,半......
阅读全文
  • 01月
  • 31日
综合 ⁄ 共 5168字 评论关闭
struts2注解 分类: Struts2 2011-04-05 10:54 746人阅读 评论(0) 收藏 举报 转载于:http://rabby.iteye.com/blog/746321   一、配置web.xml <filter> <filter-name>struts2</filter-name> <filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class> <init-param> <param-name>actionPackages</param-name> <param-value>com.test.action</param-value> </init-param> </filter> <filter......
阅读全文
  • 01月
  • 13日
综合 ⁄ 共 1182字 评论关闭
描述 从前有个人名叫W and N and B,他有着天才般的记忆力,他珍藏了许多许多的宝藏。在他离世之后留给后人一个难题(专门考验记忆力的啊!),如果谁能轻松回答出这个问题,便可以继承他的宝藏。题目是这样的:给你一大串数字(编号为1到N,大小可不一定哦!),在你看过一遍之后,它便消失在你面前,随后问题就出现了,给你M个询问,每次询问就给你两个数字A,B,要求你瞬间就说出属于A到B这段区间内的最大数。一天,一位美丽的姐姐从天上飞过,看到这个问题,感到很有意思(主要是据说那个宝藏里面藏着一种美容水,喝了可以让这......
阅读全文
  • 11月
  • 03日
综合 ⁄ 共 2082字 评论关闭
局部敏感哈希(Locality Sensitive Hashing)     计算item之间的相似项,计算item的top M最相似item,协同过滤计算(user based或item based)等等计算中,涉及大量两两相似项计算,计算复杂度为o(n2k),其中n为item量级,k为元素维度量级。即使hadoop和mpi使得模型可在多个机器或处理器协同计算,在处理o(n),nlog(n)复杂度问题时,如鱼得水。但是不说指数级的复杂度,对于m≥2的多项式级复杂度,都是一种对机器的亵渎,也成为了不是一般人或公司能玩得起的东东。     局部敏感哈希(Locality Sensitive Hashing, LSH)通过哈......
阅读全文
  • 11月
  • 01日
综合 ⁄ 共 7393字 评论关闭
原文: http://www.textfixer.com/resources/css-tables.php#css-table01    一个像素边框的表格: table.gridtable { font-family: verdana,arial,sans-serif; font-size:11px; color:#333333; border-width: 1px; border-color: #666666; border-collapse: collapse; } table.gridtable th { border-width: 1px; padding: 8px; border-style: solid; border-color: #666666; background-color: #dedede; } table.gridtable td { border-width: 1px; padding: 8px; border-style: solid; border-color: #666666; background-co......
阅读全文