摘要: 25. Reverse Nodes in k-Group Given a linked list, reverse the nodes of a linked list k at a time and return its modified list. k is a positive integer 阅读全文
posted @ 2019-02-16 12:58 mingL 阅读(106) 评论(0) 推荐(0) 编辑
摘要: 24. Swap Nodes in Pairs Given a linked list, swap every two adjacent nodes and return its head. You may not modify the values in the list's nodes, onl 阅读全文
posted @ 2019-02-16 12:52 mingL 阅读(120) 评论(0) 推荐(0) 编辑
摘要: 23. Merge k Sorted Lists Merge k sorted linked lists and return it as one sorted list. Analyze and describe its complexity. Example: 阅读全文
posted @ 2019-02-16 12:48 mingL 阅读(86) 评论(0) 推荐(0) 编辑
摘要: 22. Generate Parentheses Given n pairs of parentheses, write a function to generate all combinations of well-formed parentheses. For example, given n  阅读全文
posted @ 2019-02-16 12:46 mingL 阅读(92) 评论(0) 推荐(0) 编辑
摘要: 21. Merge Two Sorted Lists Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of th 阅读全文
posted @ 2019-02-16 12:44 mingL 阅读(150) 评论(0) 推荐(0) 编辑
摘要: 20. Valid Parentheses Given a string containing just the characters '(', ')', '{', '}', '[' and ']', determine if the input string is valid. An input 阅读全文
posted @ 2019-02-16 12:39 mingL 阅读(108) 评论(0) 推荐(0) 编辑
摘要: 19. Remove Nth Node From End of List Given a linked list, remove the n-th node from the end of list and return its head. Example: 阅读全文
posted @ 2019-02-16 12:36 mingL 阅读(120) 评论(0) 推荐(0) 编辑
摘要: 18. 4Sum Given an array nums of n integers and an integer target, are there elements a, b, c, and d in nums such that a + b + c + d = target? Find all 阅读全文
posted @ 2019-02-16 12:32 mingL 阅读(126) 评论(0) 推荐(0) 编辑