LeetCode | 149 Max Points on a Line | Python3 | Explanation

  Рет қаралды 942

ygongcode

ygongcode

Күн бұрын

Пікірлер: 2
@JohnDoe19754
@JohnDoe19754 3 жыл бұрын
Thank you so much for the solution. I would really appreciate if you do not use industry grade type writer in your later videos, hahaha. Sometimes, it is difficult to hear your voice.
@parthdesai1108
@parthdesai1108 3 жыл бұрын
HERE'S THE CODE: from decimal import Decimal class Solution: def gcd(self,a,b): while b: a,b=b,a%b return a def Slope(self,point1,point2): dx=point1[0]-point2[0] dy=point1[1]-point2[1] gcd_=self.gcd(dx,dy) return (dx/gcd_,dy/gcd_) def maxPoints(self, points: List[List[int]]) -> int: if points==None: return 0 n=len(points) if n
Dynamic Programming isn't too hard. You just don't know what it is.
22:31
DecodingIntuition
Рет қаралды 197 М.
6. Monte Carlo Simulation
50:05
MIT OpenCourseWare
Рет қаралды 2 МЛН
Players push long pins through a cardboard box attempting to pop the balloon!
00:31
World’s strongest WOMAN vs regular GIRLS
00:56
A4
Рет қаралды 51 МЛН
The Traveling Salesman Problem: When Good Enough Beats Perfect
30:27
But what is the Fourier Transform?  A visual introduction.
20:57
3Blue1Brown
Рет қаралды 10 МЛН
Become A Software Engineer For Free (Class 01) - 100Devs
3:23:06
Leon Noel
Рет қаралды 684 М.
OAuth 2.0 and OpenID Connect (in plain English)
1:02:17
OktaDev
Рет қаралды 1,8 МЛН
Bfe.dev | 110. serialize and deserialize binary tree
21:34
Trapping Rain Water - Google Interview Question - Leetcode 42
23:21
Learn the Essentials of Swift in one hour
58:14
Paul Hudson
Рет қаралды 202 М.
Mastering Dynamic Programming - How to solve any interview problem (Part 1)
19:41
Swift Programming Tutorial for Beginners (Full Tutorial)
3:22:45
CodeWithChris
Рет қаралды 7 МЛН