自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(11)
  • 资源 (10)
  • 收藏
  • 关注

原创 利用table使图片在浏览器中垂直居中

这里用到了绝对位置和table:使用table将图片相对于浏览器窗口垂直居中table{ position: absolute; left: 0; top: 0; width: 100%; height: 100%;}td{ text-align:center;}

2016-08-29 23:12:14 1511

转载 Python yield 使用浅析(作者:廖雪峰)

初学 Python 的开发者经常会发现很多 Python 函数中用到了 yield 关键字,然而,带有 yield 的函数执行流程却和普通函数不一样,yield 到底用来做什么,为什么要设计 yield ?本文将由浅入深地讲解 yield 的概念和用法,帮助读者体会 Python 里 yield 简单而强大的功能。您可能听说过,带有 yield 的函数在 Python 中被称之为 generator

2016-08-25 11:40:39 3638

原创 Python中的re模块和正则表达式

re 模块是 python 标准库的一部分,它对正则表达式(regular expression)提供了支持。本文部分内容参考自《Beginning Python From Novice to Professional Second Edition》和 python 官方文档(https://docs.python.org/3/) 在测试前请导入 re 模块:import rere模块中的一些重要

2016-08-22 18:45:23 1625

原创 Python 解决 8 皇后问题

最近在学Python,很多语法都跟C/C++不同。下面是用Python写的八皇后问题,结果都以追加方式写入了1.txt文件。# coding = utf-8# n皇后问题def conflict(s, x, y): for i in range(y): if (abs(s[i] - x) == y - i) or (x == s[i]):

2016-08-21 18:50:11 1949

原创 LeetCode 104: Maximum Depth of Binary Tree 题解

这道题非常简单:LeetCode 104: Maximum Depth of Binary Tree 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 fart

2016-08-19 22:26:03 714

原创 LeetCode 258: Add Digits 题解

刚开始以为是一道水题,一下就过了,结果题没看完,要求时间复杂度为O(1)O(1)。LeetCode 258: Add Digits Given a non-negative integer num, repeatedly add all its digits until the result has only one digit.For example:Given num = 38, the pr

2016-08-18 21:03:33 852

原创 LeetCode 371: Sum of Two Integers 题解

原题如下:LeetCode 371: Sum of Two Integers Problem: Calculate the sum of two integers a and b, but you are not allowed to use the operator + and -. Example: Given a = 1 and b = 2, return 3. 题的意思是计

2016-08-17 11:48:11 945

原创 LeetCode 292: Nim Game 题解

别看题这么长,其实很简单。LeetCode 292: Nim Game Problem: You are playing the following Nim Game with your friend: There is a heap of stones on the table, each time one of you take turns to remove 1 to 3 stones

2016-08-16 23:18:12 923

原创 LeetCode 344: Reverse String 题解

从今天开始我也来刷刷 LeetCode,从最简单的题开始。LeetCode 344: Reverse StringProblem: Write a function that takes a string as input and returns the string reversed. Example: Given s = “hello”, return “olleh”.这道题很简单,就

2016-08-16 22:49:47 1099

原创 Python3中替代Python2中cmp()函数的新函数(gt,ge,eq,le,lt)

Python3中已经不能使用cmp()函数了,被如下五个函数替代:import operator #首先要导入运算符模块operator.gt(1,2) #意思是greater than(大于)operator.ge(1,2) #意思是greater and equal(大于等于)operator.eq(1,2) #意思是equal(等于)opera

2016-08-16 11:15:25 14527

原创 Python基础运算符、字符串

最近在自学python,看的是《Python基础教程》,准备把所学、所想以及所得都记录下来。因为有python2和python3两个版本,并且差别还是蛮大的,我安装的是python3,而《Python基础教程》这本书又是以python2为蓝本讲解的。学习python3,所以自然得记些笔记了。1.各种运算python3的运算很简单,主要与python2不同的就是除法了:1 + 2

2016-08-12 23:53:09 1562

2014Computer Organization and Design 5th

2014年出版 Computer Organization and Design 5th :Computer Organization and Design, 5th Edition The HardwareSoftware Interface

2016-02-24

Pattern Recognition and Machine Learning.pdf 模式识别与机器学习

Pattern Recognition and Machine Learning.pdf 模式识别与机器学习 美国Christopher M.Bishop

2015-12-16

php_enhanced_zh.chmPHP帮助文档

php_enhanced_zh.chmPHP帮助文档

2015-11-29

Introduction To Algorithms Third Edition.pdf

Introduction To Algorithms Third Edition.pdf

2015-11-29

算法导论第三版答案.pdf

算法导论第三版答案.pdf

2015-11-29

Learning_OpenCV.pdf

Learning_OpenCV.pdf英文版。学习OpenCV的权威书籍

2015-11-29

Algorithms for Image Processing and Computer Vision.pdf

Algorithms for Image Processing and Computer Vision.pdf

2015-11-29

数字图像处理与机器视觉 Visual C++与Matlab实现.pdf

数字图像处理与机器视觉 Visual C++与Matlab实现.pdf

2015-11-29

数字图象处理C源码分析

超级推荐的数字图像处理入门教程,包括图像的旋转,平移,拉伸,插值算法等等。

2015-11-28

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除