自定义博客皮肤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)
  • 资源 (22)
  • 收藏
  • 关注

原创 LeetCode215. Kth Largest Element in an Array

Find the kth largest element in an unsorted array. Note that it is the kth largest element in the sorted order, not the kth distinct element. For example, Given [3,2,1,5,6,4] and k = 2, return 5.

2016-09-16 12:22:17 426

原创 LeetCode34. Search for a Range

Given a sorted array of integers, find the starting and ending position of a given target value. Your algorithm’s runtime complexity must be in the order of O(log n). If the target is not found in th

2016-09-15 21:00:16 306

原创 LeetCode278. First Bad Version

You are a product manager and currently leading a team to develop a new product. Unfortunately, the latest version of your product fails the quality check. Since each version is developed based on the

2016-09-15 18:39:49 285

原创 LeetCode374. Guess Number Higher or Lower

We are playing the Guess Game. The game is as follows:I pick a number from 1 to n. You have to guess which number I picked. Every time you guess wrong, I’ll tell you whether the number is higher or lo

2016-09-15 18:24:58 294

原创 leetcode 72. Edit Distance

Given two words word1 and word2, find the minimum number of steps required to convert word1 to word2. (each operation is counted as 1 step.) You have the following 3 operations permitted on a word:

2016-09-15 14:53:17 565

原创 最长公共子序列

一个给定序列的子序列是在该序列中删去若干元素后得到的序列 给定两个序列X和Y,当另一序列Z既是X的子序列又是Y的子序列时,称Z是序列X和Y的公共子序列 最长公共子序列 X = (A, B, C, B, D, A, B) Y = (B, D, C, A, B, A) (B, C, B, A) (B, D, A, B)完全代码package org.fan.learn.dp;/**

2016-09-14 17:36:49 418

原创 LeetCode322. Coin Change

You are given coins of different denominations and a total amount of money amount. Write a function to compute the fewest number of coins that you need to make up that amount. If that amount of money c

2016-09-13 22:34:34 666

原创 01背包问题

小偷有一个容量为W的背包,有n件物品,第i个物品价值vi,且重wi 目标: 找到xi使得对于所有的xi = {0, 1} sum(wi*xi) <= W, 并且 sum(xi*vi)最大递归代码package org.fan.learn.dp;/** * Created by fan on 2016/9/13. */public class Bag { public static f

2016-09-13 18:48:18 368

原创 小兵向前冲

小兵向前冲N*M的棋盘上,小兵要从左下角走到右上角,只能向上或者向右走,问有多少种走法? 注意:这里说的N*M是指线段,而不是指几根竖线,几根横线。线段总是比线少1个的。下面的讨论都是基于线段的。 见下图(这个图是4*4的): 上图标注解释如下: 左下角黄色方框:起始位置 右上角黄色方框:目标位置 下边框和右边框黑色的数字0 1 2 3 4表示的是坐标 红色的方框:表示递归时的重复

2016-09-12 16:46:21 1555

原创 斐波那契数列与n!

实现斐波那契数列 0、1、1、2、3、5、8、13、21、34、…… F(0)=0,F(1)=1,F(n)=F(n-1)+F(n-2)(n≥2,n∈N*) 递归实现:package org.fan.learn.dp;/** * Created by fan on 2016/9/12. */public class Fibo { public static long[] result

2016-09-12 14:37:47 730

原创 leetcode198 House Robber

You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed, the only constraint stopping you from robbing each of them is that adjacent houses

2016-09-12 10:55:49 388

java反编译工具jd-gui

jd-gui java 反编译工具 将class文件反编译成java文件

2016-04-25

HexEditor插件

HexEditor插件 notePad++

2016-03-15

HexEditor.dll

notepad++查看二进制文件的插件

2016-03-15

junit-4.12.jar

用于写java测试单元的必须的jar包,从官网下的,肯定可用。

2015-07-13

junit-4.12

用于写java测试单元必要的jar包,这个是从官网下的,保证可用哦

2015-07-13

单链表 环 入口点 环长

求单链表是否有环,如果有环求出环的入口点及环长

2014-04-24

C51实现LCD1602

keil C51 实现LCD1602 保证能用 可以写字符串 可以写小数 main函数中有实例

2013-04-03

c51实现lcd1602四线驱动

51单片机 c51实现lcd1602四线驱动

2013-04-01

PL-2303 win7 驱动 usb RS232

PL-2303 win7 驱动 usb RS232 保证可以使用

2013-03-22

VC6.0 工具

VC6.0 工具 显示行号 智能提示 有使用说明及visual active 安装文件和破解文件

2013-01-27

keil uvision 3 注册机 带CID的

keil uvision 3 注册机 带CID的 CID=CSXRK-XZD85 LIC0=RC9U8-3AX1C-ZNSAE-CU1JS-SW7YD-VJD6F

2013-01-23

hex转coe工具

hex coe 51hex_bin corGenerator 在研究MC8051对ROM进行配置时需要coe文件,这里给出了使用keil写的流水灯的hex文件,并将其转换成了coe文件,此coe可以正常使用,并且给出了51hex_bin.exe和CoeGenerator.exe

2013-01-17

数据结构 严蔚敏 C语言版 链队列表示与实现

数据结构 严蔚敏 C语言版 链队列表示与实现 很给劲哦 绝对不会令您失望的。

2013-01-16

数据结构 严蔚敏 C语言版 行编辑程序

数据结构 严蔚敏 C语言版 行编辑程序 很给劲哦 绝对不会令您失望的。

2013-01-16

数据结构 严蔚敏 C语言版 汉诺塔

数据结构 严蔚敏 C语言版 汉诺塔 很给劲哦 绝对不会令您失望的。

2013-01-16

数据结构 严蔚敏 C语言版 数制转换

数据结构 严蔚敏 C语言版 数制转换 很给劲哦 绝对不会令您失望的。

2013-01-16

数据结构 严蔚敏 C语言版 循环队列

数据结构 严蔚敏 C语言版 循环队列 很给劲哦 绝对不会令您失望的。

2013-01-16

数据结构 严蔚敏 C语言版 顺序栈

数据结构 严蔚敏 C语言版 顺序栈 顺序栈的实现 很给劲哦 绝对不会令您失望的。

2013-01-16

数据结构 严蔚敏 C语言版 括号匹配

数据结构 严蔚敏 C语言版 括号匹配 while((c = getchar()) != EOF) { switch(c) { case '[': push(&sqSta;, c); break; case '(': push(&sqSta;, c); break; case ']': if(getTop(&sqSta;, &e)) { if(e == '[') { pop(&sqSta;, &temp;); } if(e == '(') { printf("\nnot match\n"); return ERROR; } } break; case ')': if(getTop(&sqSta;, &e)) { if(e == '(') { pop(&sqSta;, &temp;); } if(e == '[') { printf("\nnot match\n"); return ERROR; } } break; default : printf("\nerror\n"); return ERROR; break; } } if(stackEmpty(sqSta)) { printf("\nmatched\n"); } else { printf("\nnot matched\n"); }

2013-01-16

数据结构严蔚敏C语言版 迷宫

数据结构 严蔚敏 C语言版 迷宫 status mazePath(seqStack *S, posType start, posType end) { posType curPos; //current positon int curStep; //the ordinary number sElemType e; curPos = start; curStep = 1; do { if(pass(curPos)) //the current position is "accessed" { footPrint(curPos); e.ord = curStep; e.seat = curPos; e.di = 1; push(S, e); if(curPos.xPos == end.xPos && curPos.yPos == end.yPos) { return OK; //arrive at the final } curPos = nextPos(curPos, 1); curStep++; }//end of if(pass(curPos)) else //the current position is not "accessed" { if(!stackEmpty(*S)) //the stack is not empty { pop(S,&e); while(e.di == 4 && !stackEmpty(*S)) { markPrint(e.seat); //the current position must be marked by '#' pop(S,&e); }//end while if(e.di < 4) { e.di++; push(S,e); curPos = nextPos(e.seat, e.di); } }//end of if(!stackEmpty(*S)) }//end of else }while(!stackEmpty(*S)); }

2013-01-16

液晶显示12864驱动

液晶显示12864驱动适用于EasyArm1138

2012-12-04

空空如也

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

TA关注的人

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