Value & Reference types in C#. Write Better Code! @Tarodev
Value & Reference types in C#. Write Better Code!  @Tarodev
Uploaded May 2022 | Updated September 2026, 2 weeks ago
Value vs reference types. Stack vs heap. These are fundamental concepts to understand if you wish to write performant code. Learn the characteristics of value and reference types and how they're allocated to memory. Learn how StackOverflowException occurs and how to fix and prevent them.

❤️ Become a Tarobro on Patreon: patreon.com/tarodev

=========

🔔 SUBSCRIBE: bit.ly/3eqG1Z6
🗨️ DISCORD: discord.gg/tarodev
✅ MORE TUTORIALS: youtube.com/tarodev

0:00 - whatever, intro I guess
0:37 - value types / structs
2:00 - reference type / class
3:00 - stack & heap
3:27 - stack example
5:57 - heap example
8:47 - when to use one over the other
11:30 fix StackOverflowException
13:15 - Bonus: strings
Value & Reference types in C#. Write Better Code!Unity Slider in 4 Minutes - [Unity Tutorial]Radial Formations in Unity #ShortsHow to make a drag and drop game in UnityIsometric Camera In UnityHow to use Layout Groups in UnityProcedural Animation in UnityTrajectory Line in Unity (This aint your mothers trajectory line)Creating a hyper casual game in 3 hoursAuto-save in Unity? About time...Unity Player Controller - Based on CelesteHow to: Unity Online Multiplayer
Tarodev |

Value & Reference types in C#. Write Better Code!

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER