There could be a thousand reasons why the Editor crashes so making a tutorial would be pretty much impossible, however learning to debug code is a skill that you should constantly be practicing.
Writing code that compiles successfully is just the beginning. How the code behaves in run-time is what really matters and this is why it is important to learn how to use the VS Debugger.
The easiest way to get started is simply to launch the editor through Visual Studio.
If you have installed Unreal Engine from the Epic Games Launcher you can choose to also install the Debug Symbols for the Editor and Source Code.
If you built the engine from source then you already have what you need.
Installing the UnrealVS extension is also a good idea.
Then pick the “Development Editor” solution configuration and Debug->Start Debugging
This will launch the Editor while attaching the Visual Studio Debugger. When the Editor crashes or hits an assert it will stop execution and you can inspect what is going on.
If this is your first time doing this it is probably going to be very confusing but start by opening the “Call Stack” window and browse through the list. You can click each line to “jump back in time”.
The “Autos” window is also interesting. This will show the Variables currently in scope.