121. Best Time to Buy and Sell Stock
121. Best Time to Buy and Sell Stock
Description
You are given an array prices
where prices[i]
is the price of a given stock on the i^th
day.
621. Task Scheduler
Description
You are given an array of CPU tasks
, each labeled with a letter from A to Z, and a number n
. Each CPU interval can be idle or allow the completion of one task. Tasks can be completed in any order, but there’s a constraint: there has to be a gap of at least n
intervals between two tasks with the same label.
1046. Last Stone Weight
102. Binary Tree Level Order Traversal
102. Binary Tree Level Order Traversal
Description
Given the root
of a binary tree, return the level order traversal of its nodes’ values. (i.e., from left to right, level by level).
97. Interleaving String
2013. Detect Squares
91. Decode Ways
90. Subsets II
84. Largest Rectangle in Histogram
84. Largest Rectangle in Histogram
Description
Given an array of integers heights
representing the histogram’s bar height where the width of each bar is 1
, return the area of the largest rectangle in the histogram.