Decoding the Fast & Slow Two Pointer Algorithm to Find Cycles in Javascript Part 2 of 3

  Рет қаралды 2,197

Coderbyte

Coderbyte

Күн бұрын

Пікірлер: 7
@laptewstein
@laptewstein 2 жыл бұрын
"Which is also kind of cool.... if you're a nerd" LOL i loved that
@kebab4640
@kebab4640 9 ай бұрын
2:00 I like what she said about imperfectionism. She seems wise, I like her.
@ordead6
@ordead6 2 жыл бұрын
Nice one. Please correct me if I'm wrong, but I guess if you first check if slow or fast pointer are equals 1 in your loop, then you will get a correct answer for: findUltimateOne(10); // true snippet: ``` while(true) { slow = findSquareSum(slow); fast = findSquareSum(findSquareSum(fast)); // first check if any pointers is equals 1. if(slow === 1 || fast === 1) return true; if(slow === fast) return false; } ``` really cool series 👍 thanks
@amorfati4559
@amorfati4559 2 жыл бұрын
Nice catch man
@cssanimationeffects2649
@cssanimationeffects2649 2 жыл бұрын
good one
@tomerdun
@tomerdun Жыл бұрын
would be great if you also analyze the runtime of the algos, thanks for the great videos :)
@hamed4451
@hamed4451 Жыл бұрын
it was great, but i guess there is some mistake , because as you show visually , fast and slow is equall , and then in this condition check for slow === 1 and return true isnt it?
Fast Inverse Square Root - A Quake III Algorithm
20:08
Nemean
Рет қаралды 5 МЛН
coco在求救? #小丑 #天使 #shorts
00:29
好人小丑
Рет қаралды 120 МЛН
My scorpion was taken away from me 😢
00:55
TyphoonFast 5
Рет қаралды 2,7 МЛН
Гениальное изобретение из обычного стаканчика!
00:31
Лютая физика | Олимпиадная физика
Рет қаралды 4,8 МЛН
Every Sorting Algorithm Explained in 120 minutes (full series)
1:57:33
Kuvina Saydaki
Рет қаралды 81 М.
This AI Robot Is Doing the Impossible - Unitree x ElizaWakesUp
9:30
Как наука победила религию
17:02
The Absolute Best Intro to Monads For Software Engineers
15:12
Studying With Alex
Рет қаралды 679 М.
5 Secrets to Stop Stuttering & Speak More Clearly!
12:44
Vinh Giang
Рет қаралды 71 М.
5 Simple Steps for Solving Dynamic Programming Problems
21:27
Reducible
Рет қаралды 1,1 МЛН
All Rust string types explained
22:13
Let's Get Rusty
Рет қаралды 195 М.
coco在求救? #小丑 #天使 #shorts
00:29
好人小丑
Рет қаралды 120 МЛН