Arcmap has (had?) a VBA IDE, that was very popular before .NET caught on.
By providing a similar tool, ArcGIS Pro would make development easier.
I read that ArcGIS Pro uses ActiPro behind the scenes.
ActiPro has a SyntaxEditor control that can be used in apps to edit C# code.
Microsoft.Net.Compilers could be used by ArcGIS Pro to compile the code into memory.
A collection of samples could also be provided, for example, see LinqPad.