随笔分类 -  Algorithms

上一页 1 2 3 4 5 6 7 ··· 9 下一页
只有注册用户登录后才能阅读该文。
posted @ 2019-12-20 04:04 Zhentiw 阅读(1) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。
posted @ 2019-12-19 03:19 Zhentiw 阅读(1) 评论(0) 推荐(0) 编辑
摘要:Write an algorithm to determine if a number is "happy". A happy number is a number defined by the following process: Starting with any positive intege 阅读全文
posted @ 2019-12-17 22:06 Zhentiw 阅读(127) 评论(0) 推荐(0) 编辑
摘要:Given a non-negative integer numRows, generate the first numRows of Pascal's triangle. In Pascal's triangle, each number is the sum of the two numbers 阅读全文
posted @ 2019-12-16 21:00 Zhentiw 阅读(96) 评论(0) 推荐(0) 编辑
摘要:Given an integer array nums, find the contiguous subarray (containing at least one number) which has the largest sum and return its sum. Example: Foll 阅读全文
posted @ 2019-12-15 22:35 Zhentiw 阅读(245) 评论(0) 推荐(0) 编辑
摘要:Given two arrays, write a function to compute their intersection. Example 1: Example 2: Input: nums1 = [4,9,5], nums2 = [9,4,9,8,4] Output: [4,9] Exam 阅读全文
posted @ 2019-12-14 18:48 Zhentiw 阅读(137) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。
posted @ 2019-12-14 00:02 Zhentiw 阅读(3) 评论(0) 推荐(0) 编辑
摘要:Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the first two lists. Example: 阅读全文
posted @ 2019-12-13 23:23 Zhentiw 阅读(156) 评论(0) 推荐(0) 编辑
摘要:Given a string, find the first non-repeating character in it and return it's index. If it doesn't exist, return -1. Examples: Note: You may assume the 阅读全文
posted @ 2019-12-13 22:36 Zhentiw 阅读(173) 评论(0) 推荐(0) 编辑
摘要:Given a column title as appear in an Excel sheet, return its corresponding column number. For example: Example 1: Example 2: Example 3: Basiclly, it i 阅读全文
posted @ 2019-12-12 19:42 Zhentiw 阅读(212) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。
posted @ 2019-12-12 03:17 Zhentiw 阅读(1) 评论(0) 推荐(0) 编辑
摘要:Given two strings s and t , write a function to determine if t is an anagram of s. Example 1: Example 2: Note:You may assume the string contains only 阅读全文
posted @ 2019-12-09 19:36 Zhentiw 阅读(173) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。
posted @ 2019-12-09 00:02 Zhentiw 阅读(1) 评论(0) 推荐(0) 编辑
摘要:Given a collection of distinct integers, return all possible permutations. Example: The idea is using recursive approach, we can define a recursive fu 阅读全文
posted @ 2019-12-08 23:06 Zhentiw 阅读(236) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。
posted @ 2019-12-08 03:30 Zhentiw 阅读(1) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。
posted @ 2019-12-08 01:27 Zhentiw 阅读(0) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。
posted @ 2019-12-07 05:31 Zhentiw 阅读(1) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。
posted @ 2019-12-07 05:08 Zhentiw 阅读(1) 评论(0) 推荐(0) 编辑
摘要:Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements. Example: Note: T 阅读全文
posted @ 2019-12-07 04:27 Zhentiw 阅读(228) 评论(0) 推荐(0) 编辑
摘要:Reverse a singly linked list. Example: Follow up: A linked list can be reversed either iteratively or recursively. Could you implement both? Approach 阅读全文
posted @ 2019-12-06 23:13 Zhentiw 阅读(216) 评论(0) 推荐(0) 编辑

上一页 1 2 3 4 5 6 7 ··· 9 下一页
点击右上角即可分享
微信分享提示