Note that this demonstrates why computers need eternal patches. Even with the very best of intentions, releasing a fix for errors introduces chance of more errors. These compound errors go all the way down, there is no full stack unwind in the quest for human beings to achieve perfection. The little flaws will always be part of life. By all means do your best, but never hope for error free perfection. A life of self punishment otherwise awaits. In the end even the most tightly held sand will slip through our fingers. All of it. Enjoy the holding of the sand and how it slips through our fingers in equal measure. Keep up your wonderful work!
Also, if I may add, that would mean that this is a Two's complement approach, which would in turn mean that the first bit is actually not exactly to store the sign as was said in this video. It is to denote a value of -128, which other values after add to. A binary 11111111 is -1 because -128 + 127 = -1. You can check for "Signed number representations" on wikipedia for such explanations along with a nice table showing all the relevant bit-to-decimal mappings.
I've been searching for a teacher to bring me from c++ to the very low level and you're the first to do it with clarity, quality video editing, and a clear love for assembly language! Thank you
For C, K&R is the perfect book. You won't get confused by the details, but it is a perfect introduction. For Unix: Stevens' APUE is like a bible (a bit outdated, but very complete, and nearly exact). For ASM: I learned a lot from the drDobbs articles about video programming.
That ending. Hahaha. I love it! You're a beautiful woman and very good at explaining technical topics. I wish you a successful journey with all of your projects. I'm learning software engineering as a 30 year old who studied history at college but failed at completing it... All techniques and methodology for researching and all the practice I received for reading and writing have been invaluable for my dubious career choices; both as a baker for a few years and now as a software engineer from now on. DCIC is also a very good resource I was lucky to find. Currently working through it. Thanks for all this content. I will tackle it fiercely after I learn C for a while.
Started to follow your class or so called lessons .. absolutely amazing.. you going to be a teacher for long long time and many more things to come …you are gifted …
It seems like I love feeling bewildered and confused, when I'm not I get bored.. Too much of it makes me take breaks of course, but somehow that feeling pulls me back to the subject or problem with new ideas
Re: Registers (18:00), x86-64 introduced new general purpose registers, which are just numbered R8-R15, so I believe the R is used now with RAX for consistency. To support this, the transition from 16-bit to 32-bit did not involve the introduction of new general purpose registers, just the extension of existing ones.
Re writing and programming being similar. One thing Ive noticed talking to writers at game companies Ive worked at is that they do a lot of similar thinking about syntax and semantics, correctness, and such Also, they have a similar situation where they will have a high level design for something, then be working on a low level piece, and the low level piece ripples into needing to change the high level. Refactoring effectively. It was eye opening when talking with them to realize we were so close in a lot of respects
A small part of me was curious about your gender identity but I also loved and love how you're a beautiful person talking eloquently and with great technical aptitude about a passion subject in a video where gender does not necessarily has to be a topic.
I work with a transgender person in the it industry and I'm continuously humbled by her knowledge, skill and friendly demeanor. I had to tell off a colleague for speaking bad of transgender people and I'm really really glad I did. People should live however they want to.
As other people have pointed out a signed integer's minimum value is one less than the negative maximum, which has the interesting side effect that the abs() of an signed integer isn't always positive.
It's actually implementation specific. Some have +0 and -0, some repurpose -0 for -1 EDIT: depends on your perspective. Are you squishing two datatypes together or are you trying to pack as much information into a byte.
Actually, signed integer types like char are usually stored in 2's complement format, which avoids having both a positive and a negative zero value. The minimum value you can represent in n bits is - 2^(n-1), while the maximum is 2^(n-1) - 1, so in case of char -128 to 127. If you look into this, it is also worth understanding how overflow works.
I think seeing a video with Lattner and Feldman (creator of Roc) and his podcast talked something about this with ‘2 complement to overflow’, which is considered standard compiler behavior. I would be lying if I said I completely understand this, but something to note. I think this behavior on both GCC and Clang. Edit: Okay so it was about SIMD and how overflow is done with SIMD. It is a fairly interesting explanation, but not so related to what you were saying I believe.
Your videos have been incredible! I've been a hobby dev for about 8 years, and always felt the need to understand how things work under the hood. I took a bootcamp (mainly web dev) last year and haven't had much luck on jobs, so I'm back in school and they are having me skip straight to cs2 and I have needed to cram C++ into my brain over the last two months (after mainly working with Python, JS, and a bit of C#), your videos have changed my perspective on so much. If I had to learn it all again, I’d be right back here. You're an amazing teaching resource and a true inspiration, I'm excited to see where the channel goes!
XORing registers (we didn't have variables per se, in a Series Six PLC registers were the variables) was the go-to way of zeroing out the registers. Kind of silly to do it this way these days, but back when 1K PLCs ran your plant, it paid to be frugal.
Great video! Interesting take on books. I own some but I don't find myself reading them. Like yourself I usually find what I need freely, and read up on it.
Hi K! Great channel. Thank you. Maybe a roadmap addition for the channel: Lambda Calculus and higher order programming. Lebec has a fantastic Lambda -> JS talk on YT and your insight into those aspects of computing would be interesting.
Oh yeah! Art Attack with Beni Weber (in the German Version) was one of my favourite TV-Shows. (at 02:21) "I wanna do this for every part of Software field..." -> Yes Please! Count me in! 👍 [EDIT] Oh and on the Topic of Games and Coding: I love to play Stationeers and Stormworks. Stationeers uses a MIPS like Assembly Language (called IC10), Stormworks uses Lua.
When i noticed that the memory diagrams addressed 4-bit values it startled me and eventually i thought that this was done just to make the diagram smaller
Regarding the pronunciation of "tuple": the word is a generalization of quintuple, sextuple, etc., so a logical pronunciation should be whatever rhymes with those words. Of course languages don't always adhere to strict logic, and Wiktionary lists a total of five different pronunciations.
And re: the IDE - it's just VS Code, no special setup. The only thing maybe somewhat unusual in what I do with VS Code is that I put the terminal in the editor area - which you can find with cmd/ctrl+shift+p "Terminal: create new terminal in editor area". The C compiler I typically use is clang (along with this template sometimes - github.com/neoeno/toy-c-project-template ) and how you install that will probably vary depending on your OS. If I'm missing something that looks different though, do point it out and I can advise!
I would like to say I paid better attention to the code and noticed all of these mistakes, but TH-cam limits me to 360p in the browser, so I'd have to download the videos and force a higher resolution, which is just annoying. In the browser all coding videos are basically just fuzz. The only correction I had for this video was already addressed by the pinned comment, but I'll add that you can simply include limits.h and print all the limits out for all the standard numerical types. I'm sure someone has a version of that somewhere, and I would post my own, but TH-cam also deletes every post I make that has a link or long tracts of code in it.
I want to get back to being able to write self-modifying code but so many of the modern systems both in hardware and software design do everything possible to prevent one from doing self-modifying code. Do you have any tips or tricks to be able to enable me to successfully do that without having to design my own operating system we're working my own little isolated virtual box(no pun intended)
bro no way i was not expecting art attack intro - good times thanks for reminding me! my favourite painting was the old haunted castle on the hill with moon BG
09:16 Your comment about ( -127 128 ) integer range is something that happens at times in the hardware world when engineers don't think of the consequences. I've had to deal with this before where for example there might be a range of RF channels displaying numbered from 1 to whatever but the program uses 0 to the highest number of channels and then when that becomes legacy code and someone new works with the code they might have a moment deciphering that fact. And the only reason you use 0 to begin a count is that it's simpler to run comparison operands. So, think about it without rushing in. Somewhat similar to all the whinging about " C is dangerous because of unsafe pointers ". Programmers need to grow up.
What i meant about Turing is that a movie was made that made some claims. He invented a computer the bomba. It was not a computer and It was not his invention it was polish. He cracked the german codes, again that was the polish. He named it after a childhood friend, that was made up. He was he was rude and anti-social, he was nice and a team player. He was discovered by a policman, that was made up. The entire movie was not real. He did work at Bletchley park and he did contribute yes. Tommy Flowers invented the first Electronic Computer. He was also at Bletchly and did most of it himself. It was way ahead of it's time. It was kept top secret. Most were destroyed but several were kept to spy on both friends and foes all the way to 1960. Since it was so top secret no one ever knew about it and it was only started to be talked about recently. He was bankrupted by the machine and the govenment gave him nothing. Again much better than Turing since he was basically killed by the government. But the amazing advanced code breaking machine of WWII in all the world was not the Bombas. Those were basic devices. The colossus was something amazing. But there is little content about it. Check out the Colossus, 11 or 12 were made. But they were not known about till much later. That was the first electronic computer.
Ooops! The signed byte range is -128 to +127. I think this is a side effect of not having +0 and -0 as valid number in the range.
Well, one for the next video 🤣 Thanks
Errata to errata is a time honoured tradition, tbh
Note that this demonstrates why computers need eternal patches. Even with the very best of intentions, releasing a fix for errors introduces chance of more errors.
These compound errors go all the way down, there is no full stack unwind in the quest for human beings to achieve perfection. The little flaws will always be part of life.
By all means do your best, but never hope for error free perfection. A life of self punishment otherwise awaits.
In the end even the most tightly held sand will slip through our fingers. All of it. Enjoy the holding of the sand and how it slips through our fingers in equal measure.
Keep up your wonderful work!
Also, if I may add, that would mean that this is a Two's complement approach, which would in turn mean that the first bit is actually not exactly to store the sign as was said in this video. It is to denote a value of -128, which other values after add to. A binary 11111111 is -1 because -128 + 127 = -1. You can check for "Signed number representations" on wikipedia for such explanations along with a nice table showing all the relevant bit-to-decimal mappings.
Happy accidents
Ha! That dig at Bret Victor.
You're a fantastic instructor. I'd been looking for your style of content since I started learning.
I've been searching for a teacher to bring me from c++ to the very low level and you're the first to do it with clarity, quality video editing, and a clear love for assembly language! Thank you
Remarkable how you got through that whole personal story without once mentioning that you're trained in computer science!
For C, K&R is the perfect book. You won't get confused by the details, but it is a perfect introduction. For Unix: Stevens' APUE is like a bible (a bit outdated, but very complete, and nearly exact). For ASM: I learned a lot from the drDobbs articles about video programming.
That ending. Hahaha. I love it! You're a beautiful woman and very good at explaining technical topics. I wish you a successful journey with all of your projects.
I'm learning software engineering as a 30 year old who studied history at college but failed at completing it... All techniques and methodology for researching and all the practice I received for reading and writing have been invaluable for my dubious career choices; both as a baker for a few years and now as a software engineer from now on. DCIC is also a very good resource I was lucky to find. Currently working through it.
Thanks for all this content. I will tackle it fiercely after I learn C for a while.
Started to follow your class or so called lessons .. absolutely amazing.. you going to be a teacher for long long time and many more things to come …you are gifted …
Art Attack Intro was sick brought back so many memories. We had an Indian Version and as a child it was my favourite show
It seems like I love feeling bewildered and confused, when I'm not I get bored.. Too much of it makes me take breaks of course, but somehow that feeling pulls me back to the subject or problem with new ideas
Re: Registers (18:00), x86-64 introduced new general purpose registers, which are just numbered R8-R15, so I believe the R is used now with RAX for consistency. To support this, the transition from 16-bit to 32-bit did not involve the introduction of new general purpose registers, just the extension of existing ones.
Re writing and programming being similar.
One thing Ive noticed talking to writers at game companies Ive worked at is that they do a lot of similar thinking about syntax and semantics, correctness, and such
Also, they have a similar situation where they will have a high level design for something, then be working on a low level piece, and the low level piece ripples into needing to change the high level. Refactoring effectively.
It was eye opening when talking with them to realize we were so close in a lot of respects
Wow art attack! That caught me completely by surprise. Such good memories.
I really like 0DE5 so far, and I loved the ending of this video Kay!!
Art attack! Blast from the past
lots of 🖤
You are really inspiring me to learn my field a bit more in depth
(funny ending btw)
Great video!! Very insightful. And the ending 💀💀💀
A small part of me was curious about your gender identity but I also loved and love how you're a beautiful person talking eloquently and with great technical aptitude about a passion subject in a video where gender does not necessarily has to be a topic.
I am also thankful to have this as non-core, background information that adds to our appreciation, but doesn't nee.... 😉
I work with a transgender person in the it industry and I'm continuously humbled by her knowledge, skill and friendly demeanor. I had to tell off a colleague for speaking bad of transgender people and I'm really really glad I did. People should live however they want to.
As other people have pointed out a signed integer's minimum value is one less than the negative maximum, which has the interesting side effect that the abs() of an signed integer isn't always positive.
It's actually implementation specific. Some have +0 and -0, some repurpose -0 for -1
EDIT: depends on your perspective. Are you squishing two datatypes together or are you trying to pack as much information into a byte.
Actually, signed integer types like char are usually stored in 2's complement format, which avoids having both a positive and a negative zero value. The minimum value you can represent in n bits is - 2^(n-1), while the maximum is 2^(n-1) - 1, so in case of char -128 to 127. If you look into this, it is also worth understanding how overflow works.
I think seeing a video with Lattner and Feldman (creator of Roc) and his podcast talked something about this with ‘2 complement to overflow’, which is considered standard compiler behavior.
I would be lying if I said I completely understand this, but something to note. I think this behavior on both GCC and Clang.
Edit: Okay so it was about SIMD and how overflow is done with SIMD. It is a fairly interesting explanation, but not so related to what you were saying I believe.
Thank you so much for bringing such gems, keep doing, you rock!
nao importa em que buraco da internet voce tenha se metido, saiba que sempre havera um brasileiro nele junto com voce. kkkkkk
Your videos have been incredible! I've been a hobby dev for about 8 years, and always felt the need to understand how things work under the hood. I took a bootcamp (mainly web dev) last year and haven't had much luck on jobs, so I'm back in school and they are having me skip straight to cs2 and I have needed to cram C++ into my brain over the last two months (after mainly working with Python, JS, and a bit of C#), your videos have changed my perspective on so much. If I had to learn it all again, I’d be right back here. You're an amazing teaching resource and a true inspiration, I'm excited to see where the channel goes!
Helo kay, your upload makes my day.
XORing registers (we didn't have variables per se, in a Series Six PLC registers were the variables) was the go-to way of zeroing out the registers. Kind of silly to do it this way these days, but back when 1K PLCs ran your plant, it paid to be frugal.
Great video! Interesting take on books. I own some but I don't find myself reading them. Like yourself I usually find what I need freely, and read up on it.
I thought it was a video edit mistake or a mind lapse. Then realized I had been tricked and laughed out loud.
Hi K! Great channel. Thank you.
Maybe a roadmap addition for the channel:
Lambda Calculus and higher order programming. Lebec has a fantastic Lambda -> JS talk on YT and your insight into those aspects of computing would be interesting.
Should maybe finish watching the video before commenting 🤣
Oh yeah! Art Attack with Beni Weber (in the German Version) was one of my favourite TV-Shows.
(at 02:21) "I wanna do this for every part of Software field..." -> Yes Please! Count me in! 👍
[EDIT] Oh and on the Topic of Games and Coding: I love to play Stationeers and Stormworks. Stationeers uses a MIPS like Assembly Language (called IC10), Stormworks uses Lua.
When i noticed that the memory diagrams addressed 4-bit values it startled me and eventually i thought that this was done just to make the diagram smaller
9:25 isn't it -128 to 127? the 0000 0000 takes one off the positive side only?
Yes. 1000 0000 is -128.
Regarding the pronunciation of "tuple": the word is a generalization of quintuple, sextuple, etc., so a logical pronunciation should be whatever rhymes with those words. Of course languages don't always adhere to strict logic, and Wiktionary lists a total of five different pronunciations.
Toople…just like potatoe or potwatoe
programming attack channel 🙏🏽🙏🏽
Grew up watching "Art Attack" and only now realising the title is a pun on "heart attack" 🤦♀
i'm pretty sure it's fart attack😒 Occam where you at?
Great video, we have a similar method of learning new stuff!
that ending 🤣
I love you so much, Kay!
Holy shit I subed your channel when it had 1k subs now you have 23k that too so fast.
love your videos kay!
lol love the video and the ending!
Woooo Devon gang 💚🤍💚
Lacky my favourite❤
You are awesome
Lovely idea!
Would you prefer a truthful tuple or a couple of tuples?
hey kay! do you have any thoughts about zig and rust?
Good video like always!
I loved art attack
Subscribed. You're obviously an excellent teacher
Linus says linux is linux, so we go with that.
But the MFer who invented the gif is WRONG
What is the debugger called again? And can you please confirm what development IDE you are using and how to set it up with a C compiler? Thank you.
the debugger is called "radare2". I don't know about the IDE though. I hope you get your answer :)
And re: the IDE - it's just VS Code, no special setup. The only thing maybe somewhat unusual in what I do with VS Code is that I put the terminal in the editor area - which you can find with cmd/ctrl+shift+p "Terminal: create new terminal in editor area". The C compiler I typically use is clang (along with this template sometimes - github.com/neoeno/toy-c-project-template ) and how you install that will probably vary depending on your OS.
If I'm missing something that looks different though, do point it out and I can advise!
trans queen we love you!!!!
Trans or not still lover them because of their quality
it doesnt matter, as long as Kay Lack doing great content, a huge wave of supports come to him/her
Imagine calling someone a "cis king".
@@flflflflflflyou rang?
^ i do that 24/7
I would like to say I paid better attention to the code and noticed all of these mistakes, but TH-cam limits me to 360p in the browser, so I'd have to download the videos and force a higher resolution, which is just annoying. In the browser all coding videos are basically just fuzz. The only correction I had for this video was already addressed by the pinned comment, but I'll add that you can simply include limits.h and print all the limits out for all the standard numerical types. I'm sure someone has a version of that somewhere, and I would post my own, but TH-cam also deletes every post I make that has a link or long tracts of code in it.
Lets go!
I want to get back to being able to write self-modifying code but so many of the modern systems both in hardware and software design do everything possible to prevent one from doing self-modifying code.
Do you have any tips or tricks to be able to enable me to successfully do that without having to design my own operating system we're working my own little isolated virtual box(no pun intended)
cool stuff
bro no way i was not expecting art attack intro - good times thanks for reminding me! my favourite painting was the old haunted castle on the hill with moon BG
art attack teach me who to drawn nice trees
🍌🍌🍌🍌🍌 BitMonky Approved Five Banana Rated!
At least nobody uses C++ to introduce OOP...before the stl standardized.
Arduino! 😮
Fortunately Factorio had the rocket. Mission accomplished. I started Minecraft before the dragon and I still haven't done that.
Wikipedia is bad. Maybe an LLM can help beginners.
Hmm, I scan and hopefully find what bits to flip or algorithm to use.
Twople tupple. My life-long struggle.
09:16 Your comment about ( -127 128 ) integer range is something that happens at times in the hardware world when engineers don't think of the consequences. I've had to deal with this before where for example there might be a range of RF channels displaying numbered from 1 to whatever but the program uses 0 to the highest number of channels and then when that becomes legacy code and someone new works with the code they might have a moment deciphering that fact. And the only reason you use 0 to begin a count is that it's simpler to run comparison operands. So, think about it without rushing in.
Somewhat similar to all the whinging about " C is dangerous because of unsafe pointers ". Programmers need to grow up.
Where did my comment disappear to?
Well?
hehehehe it is crazy that you went a whole video without talking about how you're tra-
What i meant about Turing is that a movie was made that made some claims. He invented a computer the bomba. It was not a computer and It was not his invention it was polish. He cracked the german codes, again that was the polish. He named it after a childhood friend, that was made up. He was he was rude and anti-social, he was nice and a team player. He was discovered by a policman, that was made up. The entire movie was not real. He did work at Bletchley park and he did contribute yes. Tommy Flowers invented the first Electronic Computer. He was also at Bletchly and did most of it himself. It was way ahead of it's time. It was kept top secret. Most were destroyed but several were kept to spy on both friends and foes all the way to 1960. Since it was so top secret no one ever knew about it and it was only started to be talked about recently. He was bankrupted by the machine and the govenment gave him nothing. Again much better than Turing since he was basically killed by the government. But the amazing advanced code breaking machine of WWII in all the world was not the Bombas. Those were basic devices. The colossus was something amazing. But there is little content about it. Check out the Colossus, 11 or 12 were made. But they were not known about till much later. That was the first electronic computer.
th-cam.com/video/9HH-asvLAj4/w-d-xo.html and th-cam.com/video/g2tMcMQqSbA/w-d-xo.html
Does ODE4 on rust code
sorry for bringing up more of this, but your pronunciation of POSIX is unusual to me, i prononce it more similarly to posit
Lol at the end
"For the fun of it" is a good book. Not very "educational" but nontheless fun to read.
re: reading right to left, you should have a chat with ramsey nasser! en.m.wikipedia.org/wiki/Qalb_(programming_language)