Samual Sam has Published 2492 Articles

Queue Interface In C#

Samual Sam

Samual Sam

Updated on 22-Jun-2020 08:45:39

281 Views

Queue represents a first-in, first out collection of object. It is used when you need a first-in, first-out access to items. When you add an item to the list, it is called enqueue, and when you remove an item, it is called deque.Let us see an example of the Queue ... Read More

Passing arrays to methods in C#?

Samual Sam

Samual Sam

Updated on 22-Jun-2020 08:36:43

232 Views

To pass arrays to methods, you need to pass an array as a method argument.int displaySum(int[] arr, int size) { }Now call it −sum = d.displaySum(myArr, 5 ) ;Example Live Demousing System; namespace Test {    class Demo {       int displaySum(int[] arr, int size) {     ... Read More

Chained Exceptions in C#

Samual Sam

Samual Sam

Updated on 22-Jun-2020 08:27:06

393 Views

Chained Exceptions are a chain of try-catch statements that handle exceptions. To create a chain of exceptions i.e. chained exceptions −Set the first try-catch −Examplestatic void Main(string[] args) {    try {       One();    } catch (Exception e) {       Console.WriteLine(e);    } }Now try-catch ... Read More

Abort in C#

Samual Sam

Samual Sam

Updated on 22-Jun-2020 07:52:56

485 Views

The Abort() method is used for destroying threads.The runtime aborts the thread by throwing a ThreadAbortException. This exception cannot be caught, the control is sent to the finally block if any.Use the Abort() method on a thread −childThread.Abort();Example Live Demousing System; using System.Threading; namespace MultithreadingApplication {    class ThreadCreationProgram { ... Read More

Geosynchronous and Geostationary Satellites

Samual Sam

Samual Sam

Updated on 22-Jun-2020 07:49:50

3K+ Views

Geosynchronous Satellite and Geosynchronous Orbit (GSO)A geosynchronous satellite is a communication satellite that has an orbital period same as the period of rotation of the earth. Hence, it appears to be permanently in the same area of the sky at a particular time each day when viewed by an observer ... Read More

What is the difference between objects and classes in C#?

Samual Sam

Samual Sam

Updated on 22-Jun-2020 07:42:42

203 Views

C# has object and classes like Java. 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 name of an object ... Read More

How can we overcome the property of CONCAT() function that it returns NULL if any one of the argument is NULL, especially when we want to concatenate the values from the column and any of the columns have NULL as its value?

Samual Sam

Samual Sam

Updated on 22-Jun-2020 07:39:12

247 Views

The above-said property is not useful especially in the case when we want to concatenate the values from the column and any of the columns have NULL as its value. To overcome this, we can use IFNULL() function along with CONCAT() function. To understand it, we consider the example from ... Read More

The Object Class in C#

Samual Sam

Samual Sam

Updated on 22-Jun-2020 07:38:24

1K+ Views

The Object class is the base class of all the classes in C#. It has the following methods on C#.Sr.NoMethod & Description1Equals(Object)Determines whether the specified object is equal to the current object.2Equals(Object, Object, Determines whether the specified object instances are considered equal.3Finalize()Allows an object to try to free resources4GetHashCode()default hash ... Read More

What is the difference between dynamic type variables and object type variables?

Samual Sam

Samual Sam

Updated on 22-Jun-2020 07:36:03

1K+ Views

You can store any type of value in the dynamic data type variable. Type checking for these types of variables takes place at run-time.The Object Type is the ultimate base class for all data types in C# Common Type System (CTS). The object is an alias for System. Object class. ... Read More

Increment and Decrement Operators in C#

Samual Sam

Samual Sam

Updated on 22-Jun-2020 07:34:05

5K+ Views

Increment operator increases integer value by one i.e.int a = 10; a++; ++a;Decrement operator decreases integer value by one i.e.int a = 20; a--; --a;The following is an example demonstrating increment operator −Example Live Demousing System; class Program {    static void Main() {       int a, b; ... Read More

Advertisements