Arjun Thakur has Published 1109 Articles

How to access elements from multi-dimensional array in C#?

Arjun Thakur

Arjun Thakur

Updated on 21-Jun-2020 12:54:49

230 Views

To acess element from the multi-dimensional array, just add the index for the element you want, for example −a[2, 1]The above access element from 3rd row and 2nd column ie element 3 as shown below in out [3, 4] array −0 0 1 2 2 4 3 6Let us see ... Read More

What is a recursive method call in C#?

Arjun Thakur

Arjun Thakur

Updated on 21-Jun-2020 12:49:30

240 Views

Recursive method call in C# is called Recursion. Let us see an example to calculate power of a number using recursion.Here, if the power is not equal to 0, then the function call occurs which is eventually recursion −if (p!=0) {    return (n * power(n, p - 1)); }Above, ... Read More

List down a list of the escape characters in C#

Arjun Thakur

Arjun Thakur

Updated on 21-Jun-2020 12:34:14

755 Views

The following is the list of escape characters in C# −Escape characterDescriptionPattern\aMatches a bell character, \u0007.\a\bIn a character class, matches a backspace, \u0008.[\b]{3, }\tMatches a tab, \u0009.(\w+)\t\rMatches a carriage return, \u000D. (\r is not equivalent to the newline character, .)\r(\w+)\vMatches a vertical tab, \u000B.[\v]{2, }\fMatches a form feed, \u000C.[\f]{2, }Matches ... Read More

What are the prerequisites for learning C#?

Arjun Thakur

Arjun Thakur

Updated on 21-Jun-2020 12:27:50

403 Views

To start learning C#, firstly you should have computer knowledge. With that, if you have a prior learning experience in C or C#, then it would be great.To start with C#, first install Visual Studio. The current version is Visual Studio 2017.If you want to avoid the hassles of installing ... Read More

What are string and String data types in C#?

Arjun Thakur

Arjun Thakur

Updated on 21-Jun-2020 11:53:45

524 Views

String stands for System.String whereas string is an alias in C# for System.String −For example −string str = "Welcome!";It’s not essential, but generally String is used when you work with classes −string str = String.Format("Welcome! {0}!", user);Since string is an alias for System.String. The alias for other datatypes are −EXampleobject: ... Read More

3D transforms in CSS3

Arjun Thakur

Arjun Thakur

Updated on 21-Jun-2020 08:32:01

87 Views

Using with 3d transforms, we can move element to x-axis, y-axis and z-axis.ExampleThe following an example shows the x-axis 3D transformsLive Demo                    div {             width: 200px;             height: 100px; ... Read More

What is the best IDE for C# on Linux?

Arjun Thakur

Arjun Thakur

Updated on 20-Jun-2020 17:32:40

1K+ Views

On Windows, the best IDE to run C# programs is Visual Studio. On Linux, the best IDE can be considered as Monodevelop. It is an open source IDE that allows you to run C# on multiple platforms i.e. Windows, Linux and MacOS. Monodevelop is also known as Xamarin Studio. It ... Read More

What is the base class for all exceptions in C#?

Arjun Thakur

Arjun Thakur

Updated on 20-Jun-2020 17:26:45

1K+ Views

The System.SystemException class is the base class for all predefined system exception. Some of the exception classes derived from the System.Exception class are the System.ApplicationException and System.SystemException classes.The System.ApplicationException class supports exceptions generated by application programs. Hence the exceptions defined by the programmers should derive from this class.The following are the exceptions ... Read More

What are objects in C#?

Arjun Thakur

Arjun Thakur

Updated on 20-Jun-2020 17:01:58

1K+ Views

Like any other object-oriented language, C# also has object and classes. Objects are real-world entities and instance of a class. Access the members of the class using an object.To access the class members, you need to use the dot (.) operator after the object name. The dot operator links the ... Read More

Way to increment a character in C#

Arjun Thakur

Arjun Thakur

Updated on 20-Jun-2020 16:46:52

2K+ Views

Firstly, set a character−char ch = 'K';Now simply increment it like this −ch++;If you will print the character now, it would be the next character as shown in the following example −Example Live Demousing System; using System.Collections.Generic; class Demo {    static void Main() {       char ch ... Read More

Advertisements