0% found this document useful (0 votes)
4 views5 pages

Cs Arrylist

The ArrayList class in C# is a dynamic, non-generic collection that allows storage and manipulation of objects of any type, found in the System.Collections namespace. It can grow or shrink in size, making it a flexible alternative to arrays. Users can add items of different types to an ArrayList using the Add() method.

Uploaded by

rahul kumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views5 pages

Cs Arrylist

The ArrayList class in C# is a dynamic, non-generic collection that allows storage and manipulation of objects of any type, found in the System.Collections namespace. It can grow or shrink in size, making it a flexible alternative to arrays. Users can add items of different types to an ArrayList using the Add() method.

Uploaded by

rahul kumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

< Home AI Data Science Python Machine Learning R Java H>

ArrayList in C#

By: Rajesh P.S.

The ArrayList class in C# is a dynamic, non-generic collection that provides the ability to
store and manipulate objects of any type. It is part of the System.Collections namespace.
The ArrayList is an alternative to using arrays when you need a collection that can
dynamically grow or shrink in size.

To work with an ArrayList, you first need to import the System.Collections namespace:

using System.Collections;

Next, you can create an instance of the ArrayList class:

ArrayList myArrayList = new ArrayList();

The ArrayList is initially empty, but you can add items to it using the Add() method:

myArrayList.Add("Apple");
myArrayList.Add(42);
myArrayList.Add(true);

In this example, we added a string, an integer, and a boolean value to the ArrayList. Note
that ArrayList allows storing objects of different types since it is not type-safe like generic
collections.

Continue Reading...

Next > How to use C# HashTable Class


Related Topics
How to use C# HashTable Class

How to use C# Stack Class

How to use C# Queue Class

How to use C# NameValueCollection Class

More Related Topics.....

Related Links
Byte Array to a text file

String Array to a text file

C# Tutorial
C# Overview

C# Language Basics

C# Statements

C# GUI

C# Collections

C# String

C# File Operations

C# Excel
C# Crystal Reports

C# Networking

C# Threading

C# Ado.Net

C# Data Providers

C# Dataset

C# DataAdapater

C# DataView

C# Remoting

C# XML

C# DataGridView

C# Advanced Concepts

C# Advanced Programming

Search : Mail to : [email protected]

Languages Courses

Python Artificial
Java Intelligence
Net- C# Machine
Informations.com R Learning
C Data Science
C++ Cryptography
VB.Net Bash
Assembly

Web Technologies Computer Science Examples

HTML Colors Python Examples


CSS IT and Web C# Examples
JavaScript Windows 11 JavaScript
TypeScript Difference Examples
jQuery Between
ASP.Net

Interview
Questions

Python
JavaScript
Java
jQuery
Data Science
Oops
C#
.Net Framework
Asp.Net
Vb.Net
Home | About | SiteMap | Terms
Net-Informations.com (C) 2024 All Rights Reserved. All
other trademarks are property of their respective owners.
2,579円 2,281円 3,300円 3,455円

4,200円 4,040円 5,500円 4,980円

6,600円 2,480円 3,150円 3,200円 3,850円

You might also like