辣椒の酱

尚未执佩剑,转眼即江湖


  • Home

  • Tags

  • Categories

  • Archives

  • message

  • master

一张图学会python3

Posted on 2019-12-26 | In python3

这张图包含了Python 3 几乎所有的知识点,包括输出、输入、变量、赋值、计算、模块、函数、参数、返回值、缩进、注释、for循环、条件判断、逻辑运算、字符串及格式化、转义字符、类型转换、列表,甚至也包含了点面向对象的应用(调用对象的方法)。

跟着这张图片一步一步学习,学会 Python指日可待!

Read more »

hash冲突开放地址法rehash

Posted on 2019-12-26 | In java , java基础

Hash碰撞

Hash函数就是将任意长度的输入转化成固定长度的输出的一类函数。

比如说我的输入是任意一个自然数(0,1,2,3…),而我要求经过一个函数后我的输出的数的范围要在0-9这样一个范围之间。

Read more »

算法成长之路leetcode13-14

Posted on 2019-12-24 | In algorithm

13. Roman to Integer

Roman numerals are represented by seven different symbols: I, V, X, L, C, D and M.

Read more »

贪心算法解析示例

Posted on 2019-12-22 | In algorithm

定义

贪心算法(又称贪婪算法)是指,在对问题求解时,总是做出在当前看来是最好的选择。也就是说,不从整体最优上加以考虑,他所做出的是在某种意义上的局部最优解。

贪心算法不是对所有问题都能得到整体最优解,关键是贪心策略的选择,选择的贪心策略必须具备无后效性,即某个状态以前的过程不会影响以后的状态,只与当前状态有关。

Read more »

不蒜子统计常见问题

Posted on 2019-12-21 | In 工具教程 , 博客统计插件

不蒜子统计官网:http://busuanzi.ibruce.info/

详细使用教程:http://ibruce.info/2015/04/04/busuanzi/

目前支持的功能:(两行代码,搞定计数;方便、简洁、实用)

a、显示站点总访问量

b、显示单页面访问量

Read more »

算法成长之路leetcode11-12

Posted on 2019-12-17 | In algorithm

11. Container With Most Water

Given n non-negative integers a1, a2, …, an , where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two endpoints of line i is at (i, ai) and (i, 0). Find two lines, which together with x-axis forms a container, such that the container contains the most water.

Read more »

intellj idea 详细调试代码debug

Posted on 2019-12-16 | In develop

Debug用来追踪代码的运行流程,通常在程序运行过程中出现异常,启用Debug模式可以分析定位异常发生的位置,以及在运行过程中参数的变化。通常我们也可以启用Debug模式来跟踪代码的运行流程去学习三方框架的源码。

Read more »

动态规划DP算法详解

Posted on 2019-12-14 | In algorithm

定义

动态规划(dynamic programing)和分治法类似,都是通过组合子问题的解来求解原问题的解。(在经典排序算法中的二路归并排序和快速排序都用到了分而治之的思想-分治法)。

分治法是将原问题划分为没有交集,相互独立的子问题,并分别求解后再进行合并,求出原问题的解。

动态规划应用于子问题重叠的情况,即不同的子问题具有公共的子子问题。分治法会做许多不必要的工作,它会反复地求解那些公共子问题。动态规划算法对每个子问题只求解一次,将其解保存在一个表格中,从而无需每次求解一个子子问题时都需要重新计算。

Read more »

算法成长之路leetcode9-10

Posted on 2019-12-14 | In algorithm

9. Palindrome Number

Determine whether an integer is a palindrome. An integer is a palindrome when it reads the same backward as forward.

Read more »

算法成长之路leetcode7-8

Posted on 2019-12-10 | In algorithm

7. Reverse Integer

Given a 32-bit signed integer, reverse digits of an integer.

Read more »
1…456…12
辣椒の酱

辣椒の酱

117 posts
42 categories
84 tags
RSS
© 2020 辣椒の酱
Powered by Hexo
|
Theme — NexT.Pisces v5.1.4