upd
This commit is contained in:
@@ -36,13 +36,13 @@ Output: 4
|
||||
Write your approach here.
|
||||
|
||||
** TODO Python
|
||||
#+begin_src python
|
||||
#+begin_src python :lc-problem 215 :lc-lang python3
|
||||
class Solution:
|
||||
def findKthLargest(self, nums: List[int], k: int) -> int:
|
||||
#+end_src
|
||||
|
||||
** TODO C++
|
||||
#+begin_src cpp
|
||||
#+begin_src cpp :lc-problem 215
|
||||
class Solution {
|
||||
public:
|
||||
int findKthLargest(vector<int>& nums, int k) {
|
||||
|
||||
@@ -56,7 +56,7 @@ medianFinder.findMedian(); // return 2.0
|
||||
Write your approach here.
|
||||
|
||||
** TODO Python
|
||||
#+begin_src python
|
||||
#+begin_src python :lc-problem 295 :lc-lang python3
|
||||
class MedianFinder:
|
||||
|
||||
def __init__(self):
|
||||
@@ -76,7 +76,7 @@ class MedianFinder:
|
||||
#+end_src
|
||||
|
||||
** TODO C++
|
||||
#+begin_src cpp
|
||||
#+begin_src cpp :lc-problem 295
|
||||
class MedianFinder {
|
||||
public:
|
||||
MedianFinder() {
|
||||
|
||||
@@ -56,7 +56,7 @@ twitter.getNewsFeed(1); // User 1's news feed should return a list with 1 t
|
||||
Write your approach here.
|
||||
|
||||
** TODO Python
|
||||
#+begin_src python
|
||||
#+begin_src python :lc-problem 355 :lc-lang python3
|
||||
class Twitter:
|
||||
|
||||
def __init__(self):
|
||||
@@ -84,7 +84,7 @@ class Twitter:
|
||||
#+end_src
|
||||
|
||||
** TODO C++
|
||||
#+begin_src cpp
|
||||
#+begin_src cpp :lc-problem 355
|
||||
class Twitter {
|
||||
public:
|
||||
Twitter() {
|
||||
|
||||
@@ -50,13 +50,13 @@ There are only two types of tasks, A and B, which need to be separated by 3 inte
|
||||
Write your approach here.
|
||||
|
||||
** TODO Python
|
||||
#+begin_src python
|
||||
#+begin_src python :lc-problem 621 :lc-lang python3
|
||||
class Solution:
|
||||
def leastInterval(self, tasks: List[str], n: int) -> int:
|
||||
#+end_src
|
||||
|
||||
** TODO C++
|
||||
#+begin_src cpp
|
||||
#+begin_src cpp :lc-problem 621
|
||||
class Solution {
|
||||
public:
|
||||
int leastInterval(vector<char>& tasks, int n) {
|
||||
|
||||
@@ -76,7 +76,7 @@ kthLargest.add(9); // return 8
|
||||
Write your approach here.
|
||||
|
||||
** TODO Python
|
||||
#+begin_src python
|
||||
#+begin_src python :lc-problem 703 :lc-lang python3
|
||||
class KthLargest:
|
||||
|
||||
def __init__(self, k: int, nums: List[int]):
|
||||
@@ -92,7 +92,7 @@ class KthLargest:
|
||||
#+end_src
|
||||
|
||||
** TODO C++
|
||||
#+begin_src cpp
|
||||
#+begin_src cpp :lc-problem 703
|
||||
class KthLargest {
|
||||
public:
|
||||
KthLargest(int k, vector<int>& nums) {
|
||||
|
||||
@@ -44,13 +44,13 @@ Explanation: The answer [[-2,4],[3,3]] would also be accepted.
|
||||
Write your approach here.
|
||||
|
||||
** TODO Python
|
||||
#+begin_src python
|
||||
#+begin_src python :lc-problem 973 :lc-lang python3
|
||||
class Solution:
|
||||
def kClosest(self, points: List[List[int]], k: int) -> List[List[int]]:
|
||||
#+end_src
|
||||
|
||||
** TODO C++
|
||||
#+begin_src cpp
|
||||
#+begin_src cpp :lc-problem 973
|
||||
class Solution {
|
||||
public:
|
||||
vector<vector<int>> kClosest(vector<vector<int>>& points, int k) {
|
||||
|
||||
@@ -49,13 +49,13 @@ Output: 1
|
||||
Write your approach here.
|
||||
|
||||
** TODO Python
|
||||
#+begin_src python
|
||||
#+begin_src python :lc-problem 1046 :lc-lang python3
|
||||
class Solution:
|
||||
def lastStoneWeight(self, stones: List[int]) -> int:
|
||||
#+end_src
|
||||
|
||||
** TODO C++
|
||||
#+begin_src cpp
|
||||
#+begin_src cpp :lc-problem 1046
|
||||
class Solution {
|
||||
public:
|
||||
int lastStoneWeight(vector<int>& stones) {
|
||||
|
||||
Reference in New Issue
Block a user