- 博客(9)
- 收藏
- 关注
原创 [leetcode]-867. Transpose Matrix(C语言)
Given a matrix A, return the transpose of A.The transpose of a matrix is the matrix flipped over it's main diagonal, switching the row and column indices of the matrix.Example 1:Input: [[1,2,3]...
2018-09-20 11:06:23 952
原创 [leetcode]-905. Sort Array By Parity(C语言)
Given an array A of non-negative integers, return an array consisting of all the even elements of A, followed by all the odd elements of A.You may return any answer array that satisfies this conditi...
2018-09-20 00:28:00 869
原创 [leetcode]-665. Non-decreasing Array(C语言)
Given an array with n integers, your task is to check if it could become non-decreasing by modifying at most 1 element.We define an array is non-decreasing if array[i] <= array[i + 1] holds for e...
2018-09-20 00:22:50 354
原创 [leetcode]-896. Monotonic Array(C语言)
An array is monotonic if it is either monotone increasing or monotone decreasing.An array A is monotone increasing if for all i <= j, A[i] <= A[j]. An array A is monotone decreasing if for al...
2018-09-19 22:33:19 347
原创 [leetcode]-73. Set Matrix Zeroes(C语言)
Given a m x n matrix, if an element is 0, set its entire row and column to 0. Do it in-place.Example 1:Input: [ [1,1,1], [1,0,1], [1,1,1]]Output: [ [1,0,1], [0,0,0], [1,0,1]]E...
2018-09-19 00:51:28 355
原创 [leetcode]-48. Rotate Image(C语言)
You are given an n x n 2D matrix representing an image.Rotate the image by 90 degrees (clockwise).Note:You have to rotate the image in-place, which means you have to modify the input 2D matrix d...
2018-09-19 00:33:32 991
原创 [leetcode]-605. Can Place Flowers(C语言)
Suppose you have a long flowerbed in which some of the plots are planted and some are not. However, flowers cannot be planted in adjacent plots - they would compete for water and both would die.Give...
2018-09-18 13:38:16 222
原创 [leetcode]-357. Count Numbers with Unique Digits(C语言)
Given a non-negative integer n, count all numbers with unique digits, x, where 0 ≤ x < 10n.Example:Input: 2Output: 91 Explanation: The answer should be the total numbers in the range of 0 ≤ ...
2018-09-18 00:26:08 153
原创 [leetcode]-171. Excel Sheet Column Number(C语言)
Given a column title as appear in an Excel sheet, return its corresponding column number.For example: A -> 1 B -> 2 C -> 3 ... Z -> 26 AA -> 27 AB -> ...
2018-09-17 23:11:32 354
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人