Available .NET Core templates from command line Templates Short Name Language Tags Console Application console [C#], F#, VB Common/Console Class…
swap() { int a=20, b=30; a=a+b; //a=50 (20+30) b=a-b; //b=20 (50-30) a=a-b; //a=30 (50-20) }
Constructors..Special type of method to initialize an object…Always have the same name as their enclosing Class…never have a return value.…
..Cannot declare a variable of static type. ..Static classes must derive from Object…They only contain static members…They cannot be instantiated…They…
SELECT convert(varchar, getdate(), 100) — mon dd yyyy hh:mmAM (or PM) — Oct 2 2010 11:01AM SELECT convert(varchar, getdate(), 101)…
Suppose you have two date in string format and you want to subtract one from another.Here is the code snippet.…
Two Types Lambda Expressions It’s basically concept used in C# 3.0. Framework 3.5 should always use lambda expression instead of…
No null terminating characters in C# string unlike C/C++ String and string keyword are same. String objects are immutable. Use…
Ref parameters need to be initialized before passing to a function while out parameters do not require initialization Although the…
A jagged array is an array of array. Array is a reference type. We can use foreach statement to iterate…