Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FindMedianSortedArrays ¶
FindMedianSortedArrays Problem 4 There are two sorted arrays nums1 and nums2 of size m and n respectively. Find the median of the two sorted arrays. The overall run time complexity should be O(log (m+n)). You may assume nums1 and nums2 cannot be both empty.
func LengthOfLongestSubstrings ¶
LengthOfLongestSubstrings Problem 3 Given a string, find the length of the longest substring without repeating characters.
Types ¶
type CycleQueue ¶
type CycleQueue struct {
// contains filtered or unexported fields
}
CycleQueue 循环队列 循环队列:入栈 tail 游标移动,出栈 head 游标移动。 栈满:(tail + 1) % len(element) == head (此处踩了坑) 栈空:head,tail = -1,-1
type ListNode ¶
ListNode list node struct
func AddTwoNumbers ¶
AddTwoNumbers Problem 2 You are given two non-empty linked lists representing two non-negative integers.
The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and return it as a linked list.
You may assume the two numbers do not contain any leading zero, except the number 0 itself.