Hello friends, Below are the available ways in C# when you cast one data type to another. Direct casting Direct cast is most common way of casting one type to another, however it yields exception if casting can’t be done. Below is the example to demonstrate the same. object length = 3.2; int test = (int)length; //Fails in… Continue reading Direct Casting, IS and AS Operator in C#
Category: .NET/C#
Working With Async Main In C# 7.1
Hello folks! I am here to present the series related to C# 7.1’s new features. In the first part, we will be going through one of the important features called async main. async main Starting with C# 7.1, the main function that is the entry point of the application can have async. Before C# 7.1,… Continue reading Working With Async Main In C# 7.1