题目:You are given annxn2D matrix representing an image.Rotate the image by 90 degrees (clockwise).Follow up:Could you do this in-place?代码:oj测试通过Runtime...
分类:
编程语言 时间:
2015-01-18 23:59:42
阅读次数:
467
Follow up for problem "Populating Next Right Pointers in Each Node".What if the given tree could be any binary tree? Would your previous solution stil...
分类:
其他好文 时间:
2015-01-18 17:05:52
阅读次数:
261
标题:Binary Tree Level Order Traversal II通过率:30.5%难度:简单Given a binary tree, return thebottom-up level ordertraversal of its nodes' values. (ie, from lef...
分类:
其他好文 时间:
2015-01-18 13:02:13
阅读次数:
151
Problem Description
You travel a lot by bus and the costs of all the seperate tickets are starting to add up.
Therefore you want to see if it might be advantageous for you to buy a bus pass.
...
分类:
其他好文 时间:
2015-01-18 11:56:00
阅读次数:
246
本文是在学习中的总结,欢迎转载但请注明出处:http://blog.csdn.net/pistolove/article/details/42833739
Given a linked list, determine if it has a cycle in it.
Follow up:
Can you solve it without using extra space?
思路:...
分类:
其他好文 时间:
2015-01-18 10:35:13
阅读次数:
157
#!/usr/bin/python# Filename: backup_ver4.pyimportosimporttime# 1. The files and directories to be backed up are specified in a list.source = ['/home/s...
分类:
编程语言 时间:
2015-01-17 23:21:17
阅读次数:
249
1 题目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 t...
分类:
其他好文 时间:
2015-01-17 11:07:27
阅读次数:
171
Description A common pastime for poker players at a poker table is to shuffle stacks of chips. Shuffling chips is performed by starting with two st...
分类:
其他好文 时间:
2015-01-16 23:40:54
阅读次数:
326
Follow up for "Unique Paths":Now consider if some obstacles are added to the grids. How many unique paths would there be?An obstacle and empty space i...
分类:
其他好文 时间:
2015-01-16 23:38:32
阅读次数:
178
题目:Follow up for "Remove Duplicates":What if duplicates are allowed at mosttwice?For example,Given sorted array A =[1,1,1,2,2,3],Your function should ...
分类:
编程语言 时间:
2015-01-16 23:36:59
阅读次数:
686