码迷,mamicode.com
首页 >  
搜索关键字:leecode    ( 178个结果
LeeCode-Invert Binary Tree
Invert a binary tree. 4 / \ 2 7 / \ / \1 3 6 9to 4 / \ 7 2 / \ / \9 6 3 1 1 /** 2 * Definition for a binary tre...
分类:其他好文   时间:2015-07-20 10:35:00    阅读次数:93
LeeCode-Merge Sorted Array
Given two sorted integer arraysnums1andnums2, mergenums2intonums1as one sorted array.Note:You may assume thatnums1has enough space (size that is great...
分类:其他好文   时间:2015-07-20 10:33:13    阅读次数:108
LeeCode-Delete Node in a Linked List
Write a function to delete a node (except the tail) in a singly linked list, given only access to that node.Supposed the linked list is1 -> 2 -> 3 -> ...
分类:其他好文   时间:2015-07-20 10:32:13    阅读次数:142
LeeCode-Spiral Matrix II
Given an integern, generate a square matrix filled with elements from 1 ton2in spiral order.For example,Givenn=3,You should return the following matri...
分类:其他好文   时间:2015-07-20 10:30:20    阅读次数:108
LeeCode-Number of 1 Bits
Write a function that takes an unsigned integer and returns the number of ’1' bits it hasFor example, the 32-bit integer ’11' has binary representatio...
分类:其他好文   时间:2015-07-20 10:29:37    阅读次数:104
LeeCode-Majority Element
Given an array of sizen, find the majority element. The majority element is the element that appears more than? n/2 ?times.You may assume that the arr...
分类:其他好文   时间:2015-07-20 10:29:23    阅读次数:100
LeeCode-Sort Colors
Given an array withnobjects colored red, white or blue, sort them so that objects of the same color are adjacent, with the colors in the order red, wh...
分类:其他好文   时间:2015-07-20 10:27:23    阅读次数:109
LeeCode-Contains Duplicate
Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears at least twice in the arr...
分类:其他好文   时间:2015-07-20 10:27:15    阅读次数:121
LeeCode-Same Tree
Given two binary trees, write a function to check if they are equal or not.Two binary trees are considered equal if they are structurally identical an...
分类:其他好文   时间:2015-07-19 21:37:22    阅读次数:139
LeeCode-String to Integer (atoi)
Implementatoito convert a string to an integer.Hint:Carefully consider all possible input cases. If you want a challenge, please do not see below and ...
分类:其他好文   时间:2015-07-19 21:27:59    阅读次数:134
178条   上一页 1 ... 11 12 13 14 15 ... 18 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!