
The using statement in C#
The using statement in C# is a form of shortcut for try and finally block of code. Things to note is in order to use the using statement the object needs to implement the IDisposable interface, and using does not…
Practical guides on AI agents, LLM security, C#/.NET and Cloud, from Taswar Bhatti

The using statement in C# is a form of shortcut for try and finally block of code. Things to note is in order to use the using statement the object needs to implement the IDisposable interface, and using does not…

In interviews there is always the Singleton question, I personally refuse to answer it on interview. The reason is very simple I don’t code singletons anymore. I use my IoC Container to provide me with a singleton. Sorry if you…
Read more: I refuse to answer your stupid singleton question in interview

C# has the as keyword, it is mainly used to cast object of one type to another, and if it fails it should return a null rather than crashing the program or throwing exception. From MSDN documentation it states: You…

So C# what is the yield keyword? The yield keyword in C# is basically an iterator, its a form of syntactic sugar added from C# 2.0 to create IEnumerable and IEnumerator objects, thus returning one element at a time. From…

In C# if one wishes to use C# constructor overloading they can use the “this” keyword right after to initialize the object, the only thing to note is one will not be able to do any validation of the data…