AmitDiwan has Published 10744 Articles

Creating a synchronized wrapper for the ArrayList in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 11:29:24

139 Views

To create a synchronized wrapper for the ArrayList, the code is as follows −Example Live Demousing System; using System.Collections; public class Demo {    public static void Main() {       ArrayList arrList = new ArrayList();       arrList.Add("AB");       arrList.Add("CD");       arrList.Add("EF");     ... Read More

Check if the ArrayList has a fixed size in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 11:26:13

181 Views

To check if the ArrayList has a fixed size, the code is as follows −Example Live Demousing System; using System.Collections; public class Demo {    public static void Main(String[] args) {       ArrayList list1 = new ArrayList();       list1.Add("One");       list1.Add("Two");       list1.Add("Three"); ... Read More

Check if ArrayList is Synchronized (thread safe) in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 11:24:52

303 Views

To check if ArrayList is synchronized, the code is as follows −Example Live Demousing System; using System.Collections; public class Demo {    public static void Main(String[] args) {       ArrayList list1 = new ArrayList();       list1.Add("A");       list1.Add("B");       list1.Add("C");       ... Read More

Check if StringDictionary is synchronized in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 11:13:40

123 Views

To check if StringDictionary is synchronized, the code is as follows −Example Live Demousing System; using System.Collections; using System.Collections.Specialized; public class Demo {    public static void Main() {       StringDictionary strDict1 = new StringDictionary();       strDict1.Add("A", "John");       strDict1.Add("B", "Andy");       strDict1.Add("C", ... Read More

Check if a SortedList object is synchronized in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 10:55:53

156 Views

To check if a SortedList object is synchronized, the code is as follows −Example Live Demousing System; using System.Collections; public class Demo {    public static void Main() {       SortedList list = new SortedList();       list.Add("1", "One");       list.Add("2", "Two");       list.Add("3", ... Read More

Check if ListDictionary has a fixed size in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 10:52:15

197 Views

To check if ListDictionary has a fixed size, the code is as follows −Example Live Demousing System; using System.Collections; using System.Collections.Specialized; public class Demo {    public static void Main() {       ListDictionary dict1 = new ListDictionary();       dict1.Add("A", "Books");       dict1.Add("B", "Electronics");     ... Read More

Check if ListDictionary contains a specific key in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 10:44:55

123 Views

To check if ListDictionary contains a specific key, the code is as follows −Example Live Demousing System; using System.Collections; using System.Collections.Specialized; public class Demo {    public static void Main() {       ListDictionary dict1 = new ListDictionary();       dict1.Add("A", "Books");       dict1.Add("B", "Electronics");   ... Read More

Getting an enumerator that iterates through HashSet in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 10:39:43

388 Views

To get an enumerator that iterates through HashSet, the code is as follows −Example Live Demousing System; using System.Collections.Generic; public class Demo {    public static void Main(String[] args) {       HashSet set1 = new HashSet();       set1.Add("A");       set1.Add("B");       set1.Add("C");   ... Read More

Get the number of nodes contained in LinkedList in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 10:26:03

263 Views

To get the number of nodes contained in the LinkedList, the code is as follows −Example Live Demousing System; using System.Collections.Generic; public class Demo {    public static void Main() {       LinkedList list = new LinkedList();       list.AddLast("A");       list.AddLast("B");       list.AddLast("C"); ... Read More

Check if HybridDictionary has fixed size in C#

AmitDiwan

AmitDiwan

Updated on 06-Dec-2019 10:22:24

120 Views

To check if HybridDictionary has fixed size, the code is as follows −Example Live Demousing System; using System.Collections; using System.Collections.Specialized; public class Demo {    public static void Main() {       HybridDictionary dict1 = new HybridDictionary();       dict1.Add("A", "Books");       dict1.Add("B", "Electronics");       ... Read More

Advertisements