04 2020 档案

摘要:Given three integers n, m and k. Consider the following algorithm to find the maximum element of an array of positive integers: You should build the a 阅读全文
posted @ 2020-04-21 04:47 Review->Improve 阅读(623) 评论(0) 推荐(0)
摘要:Given a string containing only three types of characters: '(', ')' and '*', write a function to check whether this string is valid. We define the vali 阅读全文
posted @ 2020-04-17 23:53 Review->Improve 阅读(229) 评论(0) 推荐(0)
摘要:You are given two integer arrays nums1 and nums2 sorted in ascending order and an integer k. Define a pair (u,v) which consists of one element from th 阅读全文
posted @ 2020-04-15 03:00 Review->Improve 阅读(408) 评论(0) 推荐(0)
摘要:Given a n x n matrix where each of the rows and columns are sorted in ascending order, find the kth smallest element in the matrix. Note that it is th 阅读全文
posted @ 2020-04-15 01:57 Review->Improve 阅读(311) 评论(0) 推荐(0)
摘要:Given the array queries of positive integers between 1 and m, you have to process all queries[i] (from i=0 to i=queries.length-1) according to the fol 阅读全文
posted @ 2020-04-14 08:04 Review->Improve 阅读(720) 评论(0) 推荐(0)
摘要:Design a stack that supports push, pop, top, and retrieving the minimum element in constant time. push(x) -- Push element x onto stack. pop() -- Remov 阅读全文
posted @ 2020-04-10 22:34 Review->Improve 阅读(129) 评论(0) 推荐(0)
摘要:There are n soldiers standing in a line. Each soldier is assigned a unique rating value. You have to form a team of 3 soldiers amongst them under the 阅读全文
posted @ 2020-04-02 12:52 Review->Improve 阅读(2356) 评论(0) 推荐(0)