摘要:
Given an array, rotate the array to the right by k steps, where k is non-negative. Example 1: Input: [1,2,3,4,5,6,7] and k = 3 Output: [5,6,7,1,2,3,4] 阅读全文
posted @ 2019-11-05 15:46
CNoodle
阅读(184)
评论(0)
推荐(0)
摘要:
Given the head of a linked list, rotate the list to the right by k places. Example 1: Input: head = [1,2,3,4,5], k = 2 Output: [4,5,1,2,3] Example 2: 阅读全文
posted @ 2019-11-05 15:25
CNoodle
阅读(452)
评论(0)
推荐(0)
摘要:
Given the head of a singly linked list, group all the nodes with odd indices together followed by the nodes with even indices, and return the reordere 阅读全文
posted @ 2019-11-05 03:34
CNoodle
阅读(159)
评论(0)
推荐(0)
摘要:
Write an efficient algorithm that searches for a target value in an m x n integer matrix. The matrix has the following properties: Integers in each ro 阅读全文
posted @ 2019-11-05 02:23
CNoodle
阅读(209)
评论(0)
推荐(0)
摘要:
Write an efficient algorithm that searches for a value in an m x n matrix. This matrix has the following properties: Integers in each row are sorted f 阅读全文
posted @ 2019-11-05 02:08
CNoodle
阅读(484)
评论(0)
推荐(0)
摘要:
There is an integer array nums sorted in non-decreasing order (not necessarily with distinct values). Before being passed to your function, nums is ro 阅读全文
posted @ 2019-11-05 00:03
CNoodle
阅读(438)
评论(0)
推荐(0)

浙公网安备 33010602011771号