Given a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path from the root node down to the farthest le...
分类:
其他好文 时间:
2015-12-25 20:59:38
阅读次数:
167
由于博主常年逃课,所以期末考试期间只能突击,但偶尔还能拿个奖学金啥的,哈哈,所以近一个月没有做游戏,也没有发博客= =。。。
这个景深的方法很简单
我们需要求的是CoC(circle of confusion)模糊圈
CoC与R相关 主要原理如下图所示
alpha是透镜的半径 zf为焦点,z为物距
要求R知道一些高中的三角公式就可以了
再根据CoC决定模糊...
分类:
编程语言 时间:
2015-12-21 08:11:22
阅读次数:
186
由于博主常年逃课,所以期末考试期间只能突击,但偶尔还能拿个奖学金啥的,哈哈,所以近一个月没有做游戏,也没有发博客= =。。。这个景深的方法很简单 我们需要求的是CoC(circle of confusion)模糊圈CoC与R相关 主要原理如下图所示alpha是透镜的半径 zf为焦点,z为物距 要求R...
分类:
编程语言 时间:
2015-12-21 08:09:42
阅读次数:
216
Array filter creates a new array with all elements that pass the test implemented by the provided function. In this lesson we discuss how only a truth...
分类:
编程语言 时间:
2015-12-19 06:34:49
阅读次数:
149
Minimum Depth of Binary TreeTotal Accepted:84038Total Submissions:283068Difficulty:EasyGiven a binary tree, find its minimum depth.The minimum depth i...
分类:
其他好文 时间:
2015-12-17 10:46:14
阅读次数:
165
Maximum Depth of Binary TreeTotal Accepted:107337Total Submissions:231121Difficulty:EasyGiven a binary tree, find its maximum depth.The maximum depth ...
分类:
其他好文 时间:
2015-12-17 10:30:57
阅读次数:
147
在启动深度测试glEnable(GL_DEPTH_TEST)之后,z值较小的片元如果比z值较大的片元晚绘制,z值较小的片源将会被丢弃,如下:CELL::matrix4matRot;matRot.translate(0,0,-1);-----------Z值较大CELL::matrix4MVP1=matProj*matView*matRot;glUniformMatrix4fv(_shader._MVP,1,false..
分类:
其他好文 时间:
2015-12-13 02:24:04
阅读次数:
161
.mif和.coe这两个文件分别是Quartus和ISE的RAM和ROM的初始化文件,因此了解他们的格式,是很必要的MIF文件的格式如下:WIDTH=14; --数据宽度为14位DEPTH=2048; --数据长度为2048ADDRESS_RADIX=UNS; --地址基数十进制,二进制为BIN,十...
分类:
其他好文 时间:
2015-12-12 01:31:42
阅读次数:
298
细节问题各种虐!!其实就是简单的一个深搜看成二叉树来理解:每个节点有两个枝:入栈和出栈。剪枝操作:只有当栈顶元素和当前位置的目标字符相同时才出栈,否则就不出栈dfs写三个参数:depth搜索深度,npush压栈数,npop出栈数npush用于记录压栈数:主要判断当前压栈是否合理,以及要压入的元素在原...
分类:
其他好文 时间:
2015-12-10 23:54:14
阅读次数:
204
https://leetcode.com/problems/maximum-depth-of-binary-tree/Given a binary tree, find its maximum depth.The maximum depth is the number of nodes along ...
分类:
其他好文 时间:
2015-12-10 23:47:24
阅读次数:
159