自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(19)
  • 资源 (1)
  • 收藏
  • 关注

原创 Leetcode NO.103 Binary Tree Zigzag Level Order Traversal

本题题目要求如下:Given a binary tree, return the zigzag level order traversal of its nodes' values. (ie, from left to right, then right to left for the next level and alternate between).For example:

2015-03-21 10:09:41 355

原创 Leetcode NO.133 Clone Graph

题目要求如下:Clone an undirected graph. Each node in the graph contains a label and a list of its neighbors.OJ's undirected graph serialization:Nodes are labeled uniquely.We use # as a sep

2015-03-21 09:44:46 344

原创 Leetcode NO.186 Reverse Words in a String II

题目要求如下:Given an input string, reverse the string word by word. A word is defined as a sequence of non-space characters.The input string does not contain leading or trailing spaces and the wo

2015-03-19 06:42:54 482

原创 Leetcode NO.179 Largest Number

本题题目要求如下:Given a list of non negative integers, arrange them such that they form the largest number.For example, given [3, 30, 34, 5, 9], the largest formed number is 9534330.Note: The r

2015-03-18 06:50:51 388

原创 Leetcode NO.31 Next Permutation

本题题目要求如下:Implement next permutation, which rearranges numbers into the lexicographically next greater permutation of numbers.If such arrangement is not possible, it must rearrange it as the

2015-03-17 08:42:38 417

原创 Leetcode NO.95 Unique Binary Search Trees II

本题题目要求如下:Given n, generate all structurally unique BST's (binary search trees) that store values 1...n.For example,Given n = 3, your program should return all 5 unique BST's shown below.

2015-03-17 05:59:26 309

原创 Leetcode NO.190 Reverse Bits

题目要求如下:Reverse bits of a given 32 bits unsigned integer.For example, given input 43261596 (represented in binary as 00000010100101000001111010011100), return 964176192 (represented in binary

2015-03-13 23:43:27 353

原创 Leetcode NO.134 Gas Station

本题题目要求如下:There are N gas stations along a circular route, where the amount of gas at station i is gas[i].You have a car with an unlimited gas tank and it costs cost[i] of gas to travel fro

2015-03-13 13:10:54 366

原创 Leetcode NO.122 Best Time to Buy and Sell Stock II

本题题目要求如下:Say you have an array for which the ith element is the price of a given stock on day i.Design an algorithm to find the maximum profit. You may complete as many transactions as you l

2015-03-13 10:26:09 337

原创 Leetcode NO.121 Best Time to Buy and Sell Stock

本题题目要求如下:Say you have an array for which the ith element is the price of a given stock on dayi.If you were only permitted to complete at most one transaction (ie, buy one and sell one share of

2015-03-13 09:02:51 377

原创 Leetcode NO.191 Number of 1 Bits

本题题目要求如下:Write a function that takes an unsigned integer and returns the number of ’1' bits it has (also known as theHamming weight).For example, the 32-bit integer ’11' has binary representat

2015-03-13 07:39:28 412

原创 Leetcode NO.38 Count and Say

本题题目要求如下:The count-and-say sequence is the sequence of integers beginning as follows:1, 11, 21, 1211, 111221, ...1 is read off as "one 1" or 11.11 is read off as "two 1s" or 21.21

2015-03-05 10:12:37 332

原创 Leetcode NO.59 Spiral Matrix II

本题题目要求如下:Given an integer n, generate a square matrix filled with elements from 1 to n2 in spiral order.For example,Given n = 3,You should return the following matrix:[ [ 1, 2, 3 ],

2015-03-04 03:50:04 309

原创 Leetcode NO.54 Spiral Matrix

本题题目要求如下:Given a matrix of m x n elements (m rows, n columns), return all elements of the matrix in spiral order.For example,Given the following matrix:[ [ 1, 2, 3 ], [ 4, 5, 6 ], [ 7

2015-03-04 02:34:34 346

原创 Epic 面试专题

由于3月5号要进行Epic公司的Online Assessment,准备刷些面经做准备,毕竟这是我的第一次比较重要的面试。。这是我准备Epic技术面试的小专栏。。。希望面试的时候能做够30题+吧,这样做OA的时候会轻松一点。目前完成:29题/*************************************************我是分割线*************

2015-03-03 13:39:15 5238 4

原创 Leetcode NO.101 Symmetric Tree

本题题目要求如下:Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center).For example, this binary tree is symmetric: 1 / \ 2 2 / \ / \3 4 4 3

2015-03-03 11:53:26 430

原创 Stanford - Algorithms: Design and Analysis, Part 1 - Week 5 Assignment: Dijkstra

本次作业要求如下:In this programming problem you'll code up Dijkstra's shortest-path algorithm. Download the text file here. (Right click and save link as). The file contains an adjacency list represe

2015-03-03 09:18:43 1415

原创 Stanford - Algorithms: Design and Analysis, Part 1 - Week 4 Assignment: strongly connected component

本次作业要求如下:Question 1Download the text file here. Zipped version here. (Right click and save link as)The file contains the edges of a directed graph. Vertices are labeled as positive int

2015-03-03 07:05:28 2628

原创 Leetcode NO.160 Intersection of Two Linked Lists

本题题目要求如下:Write a program to find the node at which the intersection of two singly linked lists begins.For example, the following two linked lists:A: a1 → a2 ↘

2015-03-01 10:52:26 469

Algorithm in C++, Part 1 - Part 4

这本书是我们上课时用的教材,质量应该还算不错吧,因为没有看完,只是看上课需要的部分,所以无权评价全部东西。但是本书以及本书作者还是比较有名的,学算法的肯定都知道的。MOOC上讲课的普林斯顿大牛 相比较于传说中经典的Intro to Algorithm,真本书更侧重于算法的C++实现,而非理论,对于纯CS的学生,可以绕道。。但是对于工程类专业,这本书应该是更好的选择。 P.S.如果谁有part 5图论,跟我联系下,求分享。。。另外,如果确实是跟我积分一样少的穷人,联系我,给个邮箱,我发给你。。

2014-02-23

空空如也

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

TA关注的人

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