自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

  • 博客(6)
  • 收藏
  • 关注

原创 【LeetCode OJ 019】Remove Nth Node From End of List

题目:Given a linked list, remove the nth node from the end of list and return its head. For example: Given linked list: 1->2->3->4->5, and n = 2. After removing the second node from the end,

2015-03-31 14:53:58 605

原创 【LeetCode OJ 001】Two Sum

Given an array of integers, find two numbers such that they add up to a specific target number. The function twoSum should return indices of the two numbers such that they add up to the target, whe

2015-03-30 19:22:33 575

原创 【LeetCode OJ 169】Majority Element

题目:Given an array of size n, find the majority element. The majority element is the element that appears more than ⌊ n/2 ⌋ times. You may assume that the array is non-empty and the majority ele

2015-03-28 14:24:01 518

原创 最长公共子序列问题

问题描述:字符序列的子序列是指从给定字符序列中随意地(不一定连续)去掉若干个字符(可能一个也不去掉)后所形成的字符序列。令给定的字符序列X=“x0,x1,…,xm-1”,序列Y=“y0,y1,…,yk-1”是X的子序列,存在X的一个严格递增下标序列,使得对所有的j=0,1,…,k-1,有xij=yj。例如,X=“ABCBDAB”,Y=“BCDB”是X的一个子序列。 解决方法: 1、穷举

2015-03-24 15:58:04 489

原创 【LeetCode OJ 002】Add Two Numbers

题目:You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and return it as a l

2015-03-23 20:16:27 434

转载 C++多线程编程简单实例

C++本身并没有提供任何多线程机制,但是在windows下,我们可以调用SDK win32 api来编写多线程的程序,下面就此简单的讲一下:   创建线程的函数 HANDLE CreateThread(      LPSECURITY_ATTRIBUTES lpThreadAttributes, // SD     SIZE_T dwStackSize,      

2015-03-16 21:28:52 539

空空如也

空空如也

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

TA关注的人

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