Тёмный

Looking Under the Hood of JavaScript 

ThePrimeagen
Подписаться 413 тыс.
Просмотров 185 тыс.
50% 1

Ever wonder what in the world is going on with JS? Well in this we deep dive into v8, into the internals to figure out WTF IS GOING ON WITH SETTIMEOUT???
SMI in v8?? v8.dev/blog/po...
Aleksei: / the_kozy
Twitch
Everything is built live on twitch
Twitch : bit.ly/3xhFO3E
Discord: discord.gg/ThePrimeagen
Spotify DevHour: open.spotify.c...
Editor
All my videos are edited by Flip. Give him a follow! / flipmediaprod He is also open to do more editing, so slide deeeeeeeeep into his dms.
Join this channel to get access to perks:
/ @theprimeagen
Links
Linode: linode.com/prime
/ discord
Twitch: / theprimeagen
Insta: / theprimeagen
Twitter: / theprimeagen
VimRC & i3: github.com/The...
Keyboard 15% off bit.ly/Prime360 USE CODE PRIME360
#coding #neovim #typescript #programming #vim #softwareengineering #codinglife #webdesign #webdevelopment #webdev #javascript #rustlang #rust #twitch #twitchstreamer #programmerhumor #codinghumor #software #softwareengineer #softwaredeveloper #softwaredevelopment

Опубликовано:

 

30 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 580   
@ThePrimeagen
@ThePrimeagen Год назад
I really enjoyed making this video. Its more of a new style for me, do you like it? Should I do more of this style? (send the algorithm signals!!!)
@the_flask
@the_flask Год назад
Yes
@dhruvtekker1220
@dhruvtekker1220 Год назад
It's super complicated and i didn't understand most of it. But i liked it bc i wanna learn more about js--> c++ stuff
@matiasbpg
@matiasbpg Год назад
I loved the video. It's really difficult to give content like this that deep dive into the internals
@mouradaouinat8721
@mouradaouinat8721 Год назад
Duh
@user-alesomething123
@user-alesomething123 Год назад
Yes please, I really like that the content is aimed towards explanation for intermediary stuff. Especially the fact that you’ve posted a link for further explanation and I can go and see things I don’t understand. There’s already content on RU-vid code space aimed towards beginners and people with an agenda to obscure info to sell a course. It’s why I mostly avoid RU-vid these days and just focus on odin project.
@RunningRay9
@RunningRay9 Год назад
this shows that JS is BLAZINGLY fast. It executes a code that is supposed to take infinitely long time in just an instant. Blazingly fast
@wlockuz4467
@wlockuz4467 Год назад
It has done executing while Rust hasn't even compiled!
@wadecodez
@wadecodez Год назад
Or is it infinitely fast?
@igorordecha
@igorordecha Год назад
@@wlockuz4467 I just thought... You have an algorithm written in both JS and Rust (both in source form). You enter commands "node program.js" and "cargo build && ./target/debug/program" respectively and measure time from pressing enter to the program returning. How large the input must be (the N in big O notation) for rust to win? Then check how building for production changes the results.
@kamuridesu
@kamuridesu Год назад
@@igorordecha I made this test some time ago with python and it really depends on the operation and performance of the machine. Using an 7th gen Intel core i7 and a simples multiplication operation, even with compilation rust executed faster than Python. I assume that JavaScript has a performance similar, if not worse, than python
@HuntingKingYT
@HuntingKingYT Год назад
@@igorordecha cargo run**
@kebien6020
@kebien6020 Год назад
To summarize (please correct me if I misunderstood): - The infinity case is just special handling where it's treated the same as 0 - Any other number gets casted to a 32 bit integer so some of the bigger numbers get truncated to small or even negative values - Negative values are handled effectively the same as 0
@ricardoamendoeira3800
@ricardoamendoeira3800 Год назад
What I don't understand is if you're making a special case for infinity why would you run it immediately instead of simply not scheduling it at all?!
@MrSuperNova46
@MrSuperNova46 Год назад
@@funnyav "This is the way"
@alxandr90
@alxandr90 Год назад
@@ricardoamendoeira3800 As far as I understood, the converting of Infinity to 0 has nothing to do with `setTimeout`. Rather, `Infinity` converts to 0 if you try to treat it as an integer. If you do `Infinity | 0` you get 0.
@nathanhedglin931
@nathanhedglin931 Год назад
@@funnyav divide by zero would be NaN. Weird stuff
@rosenthalpiano
@rosenthalpiano Год назад
@@nathanhedglin931 setTimeout with NaN also executes immediately. Fun huh?
@mattshnoop
@mattshnoop Год назад
Excellent video. This video has less of a "look how shitty JS is" vibe and is more just a great deep dive into the internals of V8.
@ThePrimeagen
@ThePrimeagen Год назад
thats the point! no need to bag on JS, its been bagged on enough, its more "why" does it do something
@SleepeJobs
@SleepeJobs Год назад
👍👍
@ricardoamendoeira3800
@ricardoamendoeira3800 Год назад
@@ThePrimeagen Actually I think this was more the "how it happens", in the future it would be nice to include the discussions on why some decisions were made (from issue trackers, PR's, etc. For example why choose to treat infinity as 0 instead of not scheduling the callback at all.
@lawrencedoliveiro9104
@lawrencedoliveiro9104 Год назад
So basically, it is V8 that is shitty.
@jongeduard
@jongeduard Год назад
For me it's not completely the first thing about V8 that I have watched around the subject of data types. I forgot which video it was, but it was some years ago and they had a very detailed explanation about the V8 engine and how you could write your code smarter to become more high performant. They also talked about SMI numbers and how using arrays of SMI's where the most efficient ones to use (because of preventing those extra pointers and memory allocations), also how important it was in general not to mixup several types in the same array. For example 1 object or string inside your array also containing numbers makes the whole thing based on extra pointers and allocations (in other words, the whole array becomes a boxed one). It's also true the language has a ton of initial design problems. But other languages also have their issues. C and C++ have their own huge problems for example (being very unsafe and vulnerable for example). It's great that powerfull JS engines exist these days. I would like to know more about the Firefox JS engine as well. Because V8 is not the only workhorse one that exists.
@Nurof3n_
@Nurof3n_ Год назад
More videos like this one please!
@ThePrimeagen
@ThePrimeagen Год назад
ya!
@DiscipleW
@DiscipleW Год назад
​@@ThePrimeagen And make them pretty LongLongLong xD
@spicybaguette7706
@spicybaguette7706 Год назад
Massive props to the v8 devs for making a garbage (collecting) language actually performant, these optimizations are just insane. Also SO to the people working at JSC and SpiderMonkey
@ThePrimeagen
@ThePrimeagen Год назад
yayay! its nuts that v8 team is so talented they took a language that is TERRIBLE for perf and made it semi decent. its ackshually nuts.
@snoopy8870
@snoopy8870 Год назад
this type of content on programming is what we need more!!!
@chrismuga
@chrismuga Год назад
Facts
@DiscipleW
@DiscipleW Год назад
@@chrismuga
@peternoire
@peternoire Год назад
I know we are kinda making fun of JavaScript but.. its so educational it just makes me love JavaScript more. You're great at doing this type of content. Definitely do more.
@peternoire
@peternoire Год назад
I said we as in we made this video together apparently. I don't know why I typed that.
@ThePrimeagen
@ThePrimeagen Год назад
btw, i am not trying to make fun of javascript, just trying to have fun with it :) and try to explain things in a fun way!
@RainOrigami
@RainOrigami Год назад
classic case of stockholm syndrome
@peternoire
@peternoire Год назад
@@ThePrimeagen you killin it, thanks for the good content. 👍
@professornumbskull5555
@professornumbskull5555 Год назад
Yo... You love JS? Are you alright? Do you need therapy? /s
@ThePrimeagen
@ThePrimeagen Год назад
I also didn't fight anyone, i got a stye, a duct in my eye closed and eff'd me for a few days...
@tini_
@tini_ Год назад
hmmmm, your last sentence "he is the best Engineer I have ever worked with" sounded kinda sus. Blink twice with the other eye if you need help!
@lawrencedoliveiro9104
@lawrencedoliveiro9104 Год назад
Hey, it was a chance to use the old “you should see the other guy” joke ...
@headlights-go-up
@headlights-go-up Год назад
This was simultaneously interesting and confusing. I'm not smart enough for this, should I be ashamed? lol
@ThePrimeagen
@ThePrimeagen Год назад
i think you have achieved a victory?
@shekishral6570
@shekishral6570 Год назад
Very informative and interesting, please more of those videos when you brake the javascript code into c++ code!
@Vim_Tim
@Vim_Tim Год назад
Follow-up question: what does the spec say? Is this Google’s interpretation, or do all browsers implement SetTimeout this way?
@lawrencedoliveiro9104
@lawrencedoliveiro9104 Год назад
I had a look at the MDN page (probably the most readable description I could find), and apart from warning about non-numbers being implicitly coerced into numbers, it says nothing like this. There are situations where delays may last longer than expected, but they should never be shorter. So it seems like this is some kind of weird Chrome/Chromium bug.
@Vim_Tim
@Vim_Tim Год назад
@@lawrencedoliveiro9104 MDN is not a specification… I believe ECMA-262 is the authority for this behavior.
@Vim_Tim
@Vim_Tim Год назад
I found the answer: the W3C HTML5 standard says “if timeout is an Infinity value, a Not-a-Number (NaN) value, or negative, let timeout be zero.” So this is behavior is by design.
@lawrencedoliveiro9104
@lawrencedoliveiro9104 Год назад
@@Vim_Tim But that doesn’t say that large values should overflow.
@omarb155
@omarb155 Год назад
It it interesting to consider edge cases like in this video, but hopefully this issue shouldn't arise too often.
@SuperRedstoneman
@SuperRedstoneman Год назад
Saddens me that not more people are doing videos like this and there are some concepts you go through very quickly but nevertheless I like how you explained a single thing in detail quickly while throwing in knowledge and remarks about how things work
@timdithmer9184
@timdithmer9184 Год назад
This really is some next level sh*t! Thank you very much. I was already enjoying your content a lot. But this teaches people how to find out stuff by themselves, along with providing a very deep understanding of this specific topic. Again, thanks alot! MORE! :D
@ThePrimeagen
@ThePrimeagen Год назад
yayaya
@HuntingKingYT
@HuntingKingYT Год назад
It does it immediately because it’s blazingly fast.
@SoKette
@SoKette Год назад
Diving into internals is always fun ! When everything gets demystified after a long and arduous journey of grepping and filling your brain with as much as you can, it's sooooo satisfying.
@chrissaltmarsh6777
@chrissaltmarsh6777 Год назад
This is hilarious. Reminds me of an ancient Sinclair calculator, very cheap, which got things wromg; the fun was to work out why. Lack of RAM - can't deal with edge cases, oh well, WTF. Javascript does not have that excuse.
@ThePrimeagen
@ThePrimeagen Год назад
hah, i like investigations, they are funny
@DaviAreias
@DaviAreias Год назад
So basically half of time the V8 engine is checking if we wrote something stupid?
@ThePrimeagen
@ThePrimeagen Год назад
yes
@sasjadevries
@sasjadevries Год назад
So all the soydevs out there say you should use high level programming languages, to not deal with how the system functions. When in reality javascript still has weird behaviour, but does is in a way less obvious manner than C++. Can't this scripting language just be fased out by WASM ASAP?
@mediopalodev
@mediopalodev Год назад
Brilliant Video. Absolutely more, please!
@BRP-Moto-Tips
@BRP-Moto-Tips Год назад
this wasn't in the 48 hours 0 to senior dev bootcamp I did :/
@ThePrimeagen
@ThePrimeagen Год назад
You should have done the 0 to 72 hour course.
@scottiedoesno
@scottiedoesno Год назад
Love love love this video. This is the kind of stuff that really gives so much insight into what's going on behind the scenes. Thanks a ton for taking the time, not only to figure out why, but also to explain it so well.
@ThePrimeagen
@ThePrimeagen Год назад
:) ty bud !!
@npgoalkeeper
@npgoalkeeper Год назад
Reviewing an example of chromium doing something seemingly unexpected while on Firefox, truly a chad move
@Maradney
@Maradney Год назад
You've answered "why" but didn't answer "WHY?!!!"
@techmentormaria
@techmentormaria Год назад
I miss the random 'WHY JAVASCRIPT WHY' moments :D
@sooollchhu
@sooollchhu Год назад
i am gonna have to rewatch it a couple of times to understand it, my brain is not cooperating today . Thank for this video.
@Irythros2
@Irythros2 Год назад
I would have liked and subscribed, but you didn't reference Long Long Man when talking about Long Long Long Long. I expected more from you
@ThePrimeagen
@ThePrimeagen Год назад
what about my short short?
@yuceltoluyag
@yuceltoluyag Год назад
hey dude i haven't been following you for a long time. I was sad to see your eyes like that. Sounds like you've been beaten by Emacs fangirls?
@ThePrimeagen
@ThePrimeagen Год назад
yeah, she was tougher than i expected
@Luxcium
@Luxcium Год назад
Every thing he did is open source code 🎉 Including the bleeding edge of Tailwind stuff… This Man is an angel during the day and an evil monster during the night (Anyone who is capable of understanding JavaScript is weird in someway) 😅😅😅
@ThePrimeagen
@ThePrimeagen Год назад
Tytyty
@edupsousa
@edupsousa Год назад
It's kind of scary the number of assumptions or best guesses a web browser does. The last time I dove in Chromium code was to find out why it was trying to autocomplete a random text field in my form as a credit card number. Lots of obscure heuristics.
@ThePrimeagen
@ThePrimeagen Год назад
its crazy out there :)
@Sunrostern
@Sunrostern Год назад
You lost me at negative zero. But I persevered till the end to squeeze positive experience.
@Sunrostern
@Sunrostern Год назад
Who won the bar fight though?
@razorstone3088
@razorstone3088 Год назад
never looked into what the code for v8 looks like... looks interesting
@ThePrimeagen
@ThePrimeagen Год назад
its rough.
@Dima1415
@Dima1415 Год назад
You’re rough
@judedavis92
@judedavis92 Год назад
It’s actually refreshing to see a JS dev with a good understanding of under-the-good mechanics. We need more like that.
@mzg147
@mzg147 Год назад
I hate js, I am doing challenges to write web apps without touching js, but this deep dive is just great. Makes appreciating it much easier (it's still hard tho), thank you really much!
@Amy_A.
@Amy_A. Год назад
Before watching and without knowing the answer, I'm guessing it has to do with parseInt, and setTimeout might handle NaN as 0 to simplify debugging. Edit: So kinda close. I've never needed to use Infinity before, so I didn't know how it would be parsed, and I've never tried passing anything to setTimeout that wasn't a hardcoded number (or a variable with a hardcoded number), so I didn't know for sure how it would handle that. Good info, thanks for sharing, Prime!
@ThePrimeagen
@ThePrimeagen Год назад
its more confusing than that! 32 signed integer conversion babe!
@Reinales
@Reinales Год назад
🐔🐔🐔🐔🐔🐔🐔🐔🐔IT'S PRETTY LONG 🐔🐔🐔🐔🐔🐔🐔🐔🐔
@flamendless
@flamendless Год назад
What happened to your beautiful blazing face
@ThePrimeagen
@ThePrimeagen Год назад
stye in the eye
@JosephHenryDrawing
@JosephHenryDrawing Год назад
This is really important to teach that! Don't be afraid to understand the internals and check the source code. Amazing video
@stefanhall6415
@stefanhall6415 Год назад
Love your videos❤
@ThePrimeagen
@ThePrimeagen Год назад
hey thanks stefan :)
@wadecodez
@wadecodez Год назад
There is also setImmediate instead of setTimeout which in theory executes faster than setTimeout because the underlying C code executes setImmediate before it executes timers and other phases. However, phases between standard code and timers are setImmediate and close callbacks (callbacks used only for closing resources) so again in theory, as long as you don't have any setImmediate code or closing callbacks, setTimeout(0) will be just as fast as setImmediate. Guess moral of the story is only use setImmediate when you want setTimeout(0) to run before closing a resource???? This could be a whole video
@johndavidson8096
@johndavidson8096 Год назад
Great video! Love seeing in-depth JS stuff! It's crazy impressive how much work V8 does to make JS run faster
@Georgggg
@Georgggg Месяц назад
2:19 🤢🤮 typical C++ code
@zacanger
@zacanger Год назад
So in the first few seconds my mind already jumped to "32 bit signed integers" and it turns out that was right, but I didn't know the default behavior for something larger was 0. The spec is really fascinating, especially since it includes so much stuff that JS users (like me) would love to see changed, but it can never change because JS has to be backwards-compatible forever. There's always a _logical_ explanation for JS weirdness that made sense at one point in time, but that doesn't mean it's always rational in 2023 (except for typeof null, which was just an accident, but now we're stuck with it).
@MyAmazingUsername
@MyAmazingUsername Год назад
Woof all that conversion code makes it a miracle that V8 is as fast as it is... But will it ever be BLAZINGLY FAST? No, for that we need Rust of course.
@carriagereturned3974
@carriagereturned3974 Год назад
So in order to code in JS you have to actually dig V8 C++ sauce. NICE! So you actually (literally) code in C++. That is awesome. Tell that to pythonistas who want to code in python instead of javascript for web. They will be happy to hear that))))))))))
@SoulExpension
@SoulExpension Месяц назад
He just described why js sucks. I'm not enamoured. GIGO. The type address spec is fine, that's not the problem. It's like driving a flaming train wreck through a pinhole. If not int32, truncate all common sense and make it work. Just like a financial manager.
@TeamEternalEmpire
@TeamEternalEmpire Год назад
Is there a way to prevent that 'immediately' and 'never' behavior? If we are dynamically writing a value, it can lead to a bug that may be impossible to find
@JayOhm
@JayOhm Год назад
6:00 "instant promotion" lol, more like "instant getting fired". But if you manage to not get fired, you can become "indispensable", because no one else will be able to maintain your code…
@iamtheV0RTEX
@iamtheV0RTEX Год назад
TL;DR: Numerical data types exist even if JavaScript tried to pretend they don't. Which is, again, why Rust is superior, there is absolutely no way to accidentally turn f64::INFINITY into (0 as i32).
@marcoaugustovitangeli1300
@marcoaugustovitangeli1300 Год назад
I really enjoyed this video, this kind of content is great, is beautiful to see how "high-level" code, works all the way down and spot this kind of tricky things.
@ThePrimeagen
@ThePrimeagen Год назад
:)
@lunafoxfire
@lunafoxfire Год назад
My god I do not envy the people that wrote/maintain the V8 engine. Having to translate JS and all of its garbage into C++ and all of _its_ garbage. That's gotta take like 10 years off your life.
@costelinha1867
@costelinha1867 Год назад
"So what's wrong with this code? at first thought you'd say that it's not Rust, which would be correct, but not this time." Me: I KNOW WHAT'S WRONG! Me: It's not Python.
@jongeduard
@jongeduard Год назад
I expect (and hope) enough people will have understood Two's complement before 19 January 2038 at 03:14:07 UTC. :P
@palaciokaesar
@palaciokaesar Год назад
an programmer youtube with a huge charisma??? YES I AM INNNN
@dzisonline
@dzisonline Год назад
Nice find. Looks like that's correctable then since someone purposefully wrote it to behave weirdly.
@complexity5545
@complexity5545 Год назад
Only use JS for GUI front-end button presses and easy stuff (like a shopping cart or to simply move some sprite during a game). I've been coding javascript,ecmscript,typescript,actionscript since 1999. All the many design flaws of JS is why I stopped using 3rd party JS libraries. At one time I used clojurescript. Facebook basically stole Clojurescript design and called it ReactJS. Now even React cannot overcome some of the design flaws of V8 or any other javascript runtime. It's just sad that some startups are using JS as the main language. Every startup I see using JS on the server, dies in 2-3 years (or less).
@bozhidaratanasov7800
@bozhidaratanasov7800 Год назад
Do bridge methods actually receive arrays or vectors? I would assume it's vectors, since, AFAIK, JS functions accept an arbitrary number of arguments.
@gosnooky
@gosnooky Год назад
C'mon, dev community. We need a TS compiler/engine/runtime that eschews JS and just compiles to executable byte code. JS compatibility be dammed. Separate floats and ints, instanceof on interfaces, cascade operator, immutable array HOF's, better enums, coalesce null and undefined. I mean, what I've described is basically Dart, but I hate Dart's three-slash doc blocks - slash, star, star forever. The compiler and runtime should be written in Rust, so it's bazingly fast.
@CallousCoder
@CallousCoder Год назад
Don’t pop the hood! Some engines should never be looked at because ignorance is a bliss.
@bashbunni
@bashbunni Год назад
This is amazing! You crushed this new format 🔥
@ThePrimeagen
@ThePrimeagen Год назад
oh bash... stawp
@J4j4yd3r
@J4j4yd3r Год назад
> "and then explain how you know 2's complement. instant promotion!" can I get a SLA on this strategy before I attempt it? How many 9s are we talking about? 😁
@michaeldeloatch7461
@michaeldeloatch7461 Год назад
I'm a little stopped up in the ears tonight, and a lot hearing impaired every night, and the speakers on my laptop are lousy. @ 2:40 I thought you said "ideologue" which certainly could figure in philosophically between the loosy-goosy world of JS and the cold, heartless metal of C calls ;-) -- oh, you actually said IDLong
@avinashthakur80
@avinashthakur80 Год назад
Even worst issue I found in JavaScript is that +0 & -0 are different concepts and in some situations give different results.
@ThePrimeagen
@ThePrimeagen Год назад
so... that is a funny thing. -0 and +0 is the IEEE standard, not js :)
@avinashthakur80
@avinashthakur80 Год назад
@@ThePrimeagen Yes it's IEEE standard but only in JS we see it's worst implementation. For example, these 2 expressions give different results. Math.atan2(-0, -1) Math.atan2(0, -1)
@softwarelivre2389
@softwarelivre2389 Год назад
@@avinashthakur80 As they should. It would be clear for anyone that has studied limits in Calculus classes
@avinashthakur80
@avinashthakur80 Год назад
@@softwarelivre2389 Limits don't apply here. Limit(x→-0) f(x) is different and not equivalent to f(-0) or f(0) In Math, there's no concept of "-0", it is equal to "0".
@softwarelivre2389
@softwarelivre2389 Год назад
@@avinashthakur80 0- and 0+ are literally lim x-> 0- x and lim x->0+ x
@mvargasmoran
@mvargasmoran Год назад
Why follow Aleksei on twitter? why twitter?😔
@ThePrimeagen
@ThePrimeagen Год назад
YOU KNOW WHY, HE IS AWESOME
@sculpt0r
@sculpt0r Год назад
So, it seems you can't say 'vim' & 'rust' everywhere without being hit... ;P Anyway - thanks for the video :)
@cianmoriarty7345
@cianmoriarty7345 Год назад
ThePrimagen, can you use your powers as a Sith Lord to capture whoever is responsible for JavaScript and torture them until they add actual counting types? Thankyou 🙏
@danielnoriega6655
@danielnoriega6655 11 месяцев назад
I know 2s complement, single and double bit parity for error verifications... can I get a job?
@Tony-dp1rl
@Tony-dp1rl Год назад
"It's not Rust" ... for Web Development ... are you masochistic?
@alexandersemionov5790
@alexandersemionov5790 Год назад
oh that is why ... I wonder if webkits implementation is same or how far chromium diverged
@treebeard2416
@treebeard2416 Год назад
I guess my earlier comment was deleted as it had a link(to css contain web IDL spec as an example)? All the IDL prefixes stand for Interface Definition Language, every web spec defines a web IDL for browser vendors to implement the feature properly. Also the spec says to make the timeout call to run for 4ms if there are more than 5 nesting levels of timeout calls.
@softed
@softed Год назад
The infinity thing I can understand, but the rest is just integer overflow which can happen in most languages including rust
@matthewvaccaro8877
@matthewvaccaro8877 Год назад
More! More you son of a bitxh!!! More content like this, it’s absolutely amazing ❤❤❤
@MrLowbob
@MrLowbob Год назад
1. I like the video, very interesting to look under the hood like this! 2. what the actual fuck did they drink to come up with this shit (especially all the weird cases, that we know and love...) (the original javascript inventors, not the v8 team trying to make the best out of it xd)
@BoloH.
@BoloH. Год назад
JS is like double quarter pounder from Mickey Dee - a bit weird, a bit shit, you don't want anyone know you're having one but you secretly kind of like it.
@codedusting
@codedusting Год назад
Ah! Good old computer science 🤣🤣🤣
@ThePrimeagen
@ThePrimeagen Год назад
really.. the classic
@rampage_sl
@rampage_sl Год назад
Why schedule setTimeout(cb, infinite) at all? Should throw an error or something.
@nextfangtechlead6239
@nextfangtechlead6239 Год назад
JS's creator said JS should be declared obsolete by now and JS devs should move on 🤭🤭🤭🤭 ( not kidding 🤪 )
@NotTheHeroStudios
@NotTheHeroStudios Год назад
I can't find the subscribe button.. It just asks me to joint.... RU-vid must be broken. You should fix it
@coderentity2079
@coderentity2079 Год назад
Yeah, let's treat infinity as 0, let's silently chop off bits from a number, and let's treat the bit in the middle as sign. Great programming, great design. It will be kept as is, thanks to microsoft.
@priapushk996
@priapushk996 Год назад
6 minutes on two's complement. 10 seconds on black eye. Would have preferred reverse.
@dipjul
@dipjul Год назад
Let guess it before watching the answer: Is it because of integer overflow, it is the number entered is outside the range, it circle back. For example: we the accept range as -1 to +1, and we enter 2, the it get takes the value -1.
@sprytnychomik
@sprytnychomik Год назад
The only difference between garbage man and a software engineer is compensation. Though, when I think about it, garbage man has much cleaner job.
@Trooperos90
@Trooperos90 3 месяца назад
What do u mean it gets translated to cpp? Its just v8 interpreter using binary code that was compiled from cpp
@washedmyhair
@washedmyhair Год назад
Have you thought about making a video about rust? You can tell your story, how you program on it or something else, for example.
@mvargasmoran
@mvargasmoran Год назад
Boy oh boy, you look rough man. got beat up by Javascript again? those beatings will continue.
@vlasynca37
@vlasynca37 Год назад
I would love it if you made a video about using performance analyser to debug javascript performance issues.
@petarkolev6928
@petarkolev6928 Год назад
This video is beyond amazing!
@ThePrimeagen
@ThePrimeagen Год назад
oh well ty :)
@ascourter
@ascourter Год назад
Nothing like pulling out the ole 2's complement to see some jaws hit the floor
@aymanougri1225
@aymanougri1225 Год назад
I NEED MORE VIDEOS MORE BLAZINGLY FASTER THAN THIS SWOLLENEYEGEN !!! (shoutout to da wife for supporting you)
@ThePrimeagen
@ThePrimeagen Год назад
hio! ty :) yeah, its really hard to live this lifestyle of 4 kids, beautiful wife, twitch, yt, netflix... oof
@collinsa8909
@collinsa8909 Год назад
Don't like c++ , it's a messy language same with c, and the explanation was over my head.
@pd5711
@pd5711 Год назад
Thanks for that video ! Props for Westbrook usage :D
@lookupverazhou8599
@lookupverazhou8599 Год назад
I clicked. But javascript is beautiful and wonderful.
@ЯрославСафонов-в6ъ
Where did you got this problematic values initially?
@chamber3593
@chamber3593 Год назад
Hey Primeagen why did you delete your mentor RU-vid shorts. And can you please make a new one instead.
@liondevelops
@liondevelops Год назад
Wow, I barely understood this, I gotta learn so much more...
@Sakrosankt-Bierstube
@Sakrosankt-Bierstube Год назад
Press the Subscribe-Button or the link? The instructions are not clear enough ,_,
@henrymaddocks984
@henrymaddocks984 Год назад
Are we just going to ignore the fact that the function is on line 21276 and we're not even 3/4 of the way into the file?
@zebedie2
@zebedie2 Год назад
Welcome to the wonderful world of two's complement where the msb represents if the number is negative.
@wingunder
@wingunder Год назад
Nice 😉, ...the video,I mean. I'd prefer some rust or neovim content.
@sethm7761
@sethm7761 Год назад
How did you edit broken javascript down to only 6 minutes?
Далее
Are Developers Ok?
11:46
Просмотров 184 тыс.
JavaScript: How It's Made
10:54
Просмотров 881 тыс.
pumpkins #shorts
00:39
Просмотров 30 млн
Почему?
00:22
Просмотров 426 тыс.
ХОККЕЙНАЯ КЛЮШКА ИЗ БУДУЩЕГО?
00:29
I Went To DEFCON!
16:25
Просмотров 242 тыс.
Is JSON Blazingly Fast or...?
9:57
Просмотров 193 тыс.
Dependency Injection, The Best Pattern
13:16
Просмотров 827 тыс.
I tried using AI. It scared me.
15:49
Просмотров 7 млн
How Slow Is JavaScript? | Prime Reacts
15:34
Просмотров 179 тыс.
Why i think C++ is better than rust
32:48
Просмотров 309 тыс.
How principled coders outperform the competition
11:11
Microservices are Technical Debt
31:59
Просмотров 371 тыс.
pumpkins #shorts
00:39
Просмотров 30 млн