Create a new string from an array of string through String.Join method

We can use String.Join method to create a new string from an array of string. Let’ say I have a array of the some words and i want to create a sentence from this array then i can use The String.Join method with an array and a separator string. Continue reading “Create a new string from an array of string through String.Join method”

Search for an element in array with Array.Find method in c#

 
Array.Find method searches for an element that matches the conditions defined by the specified predicate(The Predicate is a delegate to a method that returns true if the object passed to it matches the conditions defined in the delegate.), and returns the first occurrence within the entire specified Array.
Continue reading “Search for an element in array with Array.Find method in c#”

How to Convert Arraylist to Array in .net

Array is the group or collection of similar datatypes object and it is member of the system namespace whereas ‘Arraylist’ is the group of variables or object with different datatypes and it implement the ‘IList’ interface using an array whose size is dynamically increased as required.
Continue reading “How to Convert Arraylist to Array in .net”