Just discovered your channel a week or two ago. Good stuff. And thanks for increasing the text size in the editor on this video. The previous videos were hard to read for these old eyes. Two minor points: 1. On the initial slide showing the stack and heap, technically the reference type fields in Books (the strings) should point to other places in the heap. They're not inside the Book class directly as implied by the diagram. Although, depending on the level of abstraction you want to work at, it could be argued the slide was acceptable for an introduction. 2. Minor point at 7:46: I'm pretty sure when you pass in a ref parameter on a reference type, what's passed in is the pointer to the pointer. If it was just passing the pointer, then that copy of the pointer would be local to the stack of the method being called and wouldn't update the value for the caller. Keep up the good work! Peace!
@hubertmijalski2 жыл бұрын
Thanks for the feedback, you're right in both and both were done for the sake of simplicity just to illustrate the overall point, but you're absolutely right. Thanks!
@Raid772 жыл бұрын
Hello I'd like to ask you why doesn't this work for strings if they are on the heap as well? I tried something similar to your example and whenever I changed one of the strings the other one didn't change 😶
@vivekkaushik95082 жыл бұрын
cuz strings are immutable?
@cloudstrife70832 жыл бұрын
always funny to me when young programmer who never knew pre managed programming talk about heap vs stack in a managed language... in C++ ok but not in C# :\ weird in a way but I still understand what your trying to do/teach