xinyu04

导航

上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 30 下一页

2022年8月19日 #

[Oracle] LeetCode 1740 Find Distance in a Binary Tree

摘要: Given the root of a binary tree and two integers p and q, return the distance between the nodes of value p and value q in the tree. The distance betwe 阅读全文

posted @ 2022-08-19 03:10 Blackzxy 阅读(20) 评论(0) 推荐(0) 编辑

[Oracle] LeetCode 253 Meeting Rooms II

摘要: Given an array of meeting time intervals intervals where intervals[i] = [starti, endi], return the minimum number of conference rooms required. Soluti 阅读全文

posted @ 2022-08-19 01:56 Blackzxy 阅读(13) 评论(0) 推荐(0) 编辑

2022年8月18日 #

[Oracle] LeetCode 333 Largest BST Subtree

摘要: Given the root of a binary tree, find the largest subtree, which is also a Binary Search Tree (BST), where the largest means subtree has the largest n 阅读全文

posted @ 2022-08-18 17:10 Blackzxy 阅读(17) 评论(0) 推荐(0) 编辑

LeetCode 295 Find Median from Data Stream

摘要: The median is the middle value in an ordered integer list. If the size of the list is even, there is no middle value and the median is the mean of the 阅读全文

posted @ 2022-08-18 02:33 Blackzxy 阅读(6) 评论(0) 推荐(0) 编辑

2022年8月17日 #

LeetCode 347 Top K Frequent Elements

摘要: Given an integer array nums and an integer k, return the k most frequent elements. You may return the answer in any order. Solution 此题要求时间复杂度低于 $O(n\l 阅读全文

posted @ 2022-08-17 17:14 Blackzxy 阅读(11) 评论(0) 推荐(0) 编辑

MathProblem 38 Meeting at a restaurant problem

摘要: Two people arrive in a restaurant independently. Each arrives a random time between 5pm and 6pm, distributed uniformaly (no moment in this range is an 阅读全文

posted @ 2022-08-17 05:12 Blackzxy 阅读(13) 评论(0) 推荐(0) 编辑

MathProblem 37 Common birthday problem

摘要: What is the minimum number of people do you need, chosen at random, so that there is at least a 50% chance that at least two have the same birthday. A 阅读全文

posted @ 2022-08-17 04:55 Blackzxy 阅读(10) 评论(0) 推荐(0) 编辑

LeetCode 127 Word Ladder

摘要: A transformation sequence from word beginWord to word endWord using a dictionary wordList is a sequence of words beginWord -> s1 -> s2 -> ... -> sk su 阅读全文

posted @ 2022-08-17 04:02 Blackzxy 阅读(14) 评论(0) 推荐(0) 编辑

2022年8月16日 #

LeetCode 384 Shuffle an Array

摘要: Given an integer array nums, design an algorithm to randomly shuffle the array. All permutations of the array should be equally likely as a result of 阅读全文

posted @ 2022-08-16 21:27 Blackzxy 阅读(13) 评论(0) 推荐(0) 编辑

MathProblem 35 Light bulb problem #1

摘要: You have ten light bulbs. Five have an average life of 100 hours, and the other five have a average life of 200 hours. These light bulbs have a memory 阅读全文

posted @ 2022-08-16 06:19 Blackzxy 阅读(29) 评论(0) 推荐(0) 编辑

上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 30 下一页