描述 2007年到来了。经过2006年一年的修炼,数学神童zouyu终于把0到100000000的Fibonacci数列(f[0]=0,f[1]=1;f[i] = f[i-1]+f[i-2](i>=2))的值全部给背了下来。接下来,CodeStar决定要考考他,于是每问他一个数字,他就要把答案说出来 ...
分类:
其他好文 时间:
2018-10-25 00:16:16
阅读次数:
171
在前面一篇文章中,我们分析了Android模块的编译过程。当Android系统的所有模块都编译好之后,我们就可以对编译出来的模块文件进行打包了。打包结果是获得一系列的镜像文件,例如system.img、boot.img、ramdisk.img、userdata.img和recovery.img等。这 ...
分类:
移动开发 时间:
2018-10-24 20:28:41
阅读次数:
188
#!/usr/bin/env python # -*- coding: utf-8 -*- # 斐波那契数列 def fibonacci_sequence(num): aa = 0 b = 1 li = list() li.append(aa) li.append(b) for i in range... ...
分类:
编程语言 时间:
2018-10-23 14:59:40
阅读次数:
123
Description "Transmission Gate" 你需要维护一个长度为$n \leq 300000$ 的数列,兹词两个操作: 1.给一个区间加上一个 数列,规定$f[0] = 0, f[1] = 1, f[2] = 1$ 2.查询一段区间的和。对 取模 操作个数 不超过300000. ...
分类:
其他好文 时间:
2018-10-21 22:55:43
阅读次数:
185
JanusGraph调研 [TOC] 结论 HugeGraph基于TinkerPop,很大程度借鉴了Titan和JanusGraph项目,用到了JanusGraph的storage存储框架和Titan的schema定义框架。 Hugegraph studio, hugegraph tool是Janu ...
分类:
其他好文 时间:
2018-10-21 21:52:17
阅读次数:
3033
What are the differences between a process and a thread? How are they similar? How can 2 threads communicate? How can 2 process communicate? Both proc ...
分类:
其他好文 时间:
2018-10-18 10:54:59
阅读次数:
197
三 multiprocessing模块 Multiprocessing is a package that supports spawning processes using an API similar to the threading module. The multiprocessing pa ...
分类:
编程语言 时间:
2018-10-17 11:13:23
阅读次数:
165
Consider all the leaves of a binary tree. From left to right order, the values of those leaves form a leaf value sequence. For example, in the given t ...
分类:
其他好文 时间:
2018-10-15 12:04:24
阅读次数:
129
%% 说明:% Fibonacci为1200年代的欧洲数学家,在他的着作中曾经提到:若有一只兔子每个月生一只小兔子,一个月后也开% 始生产。起初只有一只兔子,一个月后就有两只兔子,二个月后就有三只兔子,三个月后有五只兔子(小兔子投入% 生产)……% 如果不太理解这个例子的话,举个图就知道了,注意新生 ...
分类:
编程语言 时间:
2018-10-15 11:51:42
阅读次数:
150
>>> import math>>> help(math)Help on built-in module math:NAME mathDESCRIPTION This module is always available. It provides access to the mathematical ...
分类:
编程语言 时间:
2018-10-13 00:02:19
阅读次数:
877