Problem:Reverse a linked list from position m to n. Do it in-place and in one-pass. For example:Given 1->2->3->4->5->NULL, m = 2 and n = 4,return 1->4...
分类:
其他好文 时间:
2015-06-24 12:52:00
阅读次数:
106
Sudoku Solver
class Solution:
# @param {character[][]} board
# @return {void} Do not return anything, modify board in-place instead.
def solveSudoku(self, board):
def c...
分类:
其他好文 时间:
2015-06-23 12:01:45
阅读次数:
125
Set Matrix Zeroes
欢迎大家阅读参考,如有错误或疑问请留言纠正,谢谢
Given a m x n matrix, if an element is 0, set its entire row and column to 0. Do it in place.
Follow up:
Did you use extra space?
A s...
分类:
其他好文 时间:
2015-06-22 11:12:40
阅读次数:
113
Rotate Image
欢迎大家阅读参考,如有错误或疑问请留言纠正,谢谢
You are given an n x n 2D matrix representing an image.
Rotate the image by 90 degrees (clockwise).
Follow up:
Could you do this in-place?...
分类:
其他好文 时间:
2015-06-22 11:11:54
阅读次数:
116
Reverse a linked list from positionmton. Do it in-place and in one-pass.For example:Given1->2->3->4->5->NULL,m= 2 andn= 4,return1->4->3->2->5->NULL.No...
分类:
其他好文 时间:
2015-06-20 17:00:23
阅读次数:
93
https://leetcode.com/problems/remove-element/Given an array and a value, remove all instances of that value in place and return the new length.The ord...
分类:
其他好文 时间:
2015-06-19 01:26:31
阅读次数:
146
https://leetcode.com/problems/remove-duplicates-from-sorted-array/Given a sorted array, remove the duplicates in place such that each element appear o...
分类:
其他好文 时间:
2015-06-19 01:22:40
阅读次数:
118
Reverse a linked list from position m to n. Do it in-place and in one-pass.
For example:
Given 1->2->3->4->5->NULL, m = 2 and n =
4,
return 1->4->3->2->5->NULL.
Note:
Given m, n satisfy t...
分类:
其他好文 时间:
2015-06-18 17:26:10
阅读次数:
110
//: Playground - noun: a place where people can playimport UIKitvar str = "Hello, playground"var a = 5switch a { case 4: println("yes") default: p...
分类:
编程语言 时间:
2015-06-18 00:37:25
阅读次数:
249
题目:Given an array and a value, remove all instances of that value in place and return the new length.The order of elements can be changed. It doesn't ...
分类:
编程语言 时间:
2015-06-17 23:23:07
阅读次数:
216