What are collections and generics

What are collections and generics?

E

Expert

Verified

A collection can be defined as a group of related items that can be referred to as a single unit. The System.Collections namespace provides you with many classes and interfaces. Some of them are - ArrayList, List, Stack, ICollection, IEnumerable, and IDictionary. Generics provide the type-safety to your class at the compile time. While creating a data structure, you never need to specify the data type at the time of declaration. The System.Collections.Generic namespace contains all the generic collections.

   Related Questions in Programming Languages

  • Q : Describe Layout manager Layout manager

    Layout manager: The object responsible for sharing the accessible space between multiple components in a graphical container.

  • Q : Describe Throw an exception Throw an

    Throw an exception: Whenever an exceptional circumstance occurs in a program - frequently as an outcome of a logical error and exception object is formed and thrown. When the exception is not caught by an exception handler, the program will finish wit

  • Q : Explain Virtual memory Virtual memory :

    Virtual memory: It is computer will comprise a limited amount of real memory accessible to it. Programs frequently need more memory than the quantity of real memory. Moreover, in a multiprogramming system, various processes will be competing for simil

  • Q : What is an Arithmetic expression

    Arithmetic expression: It is an expression comprising numerical values of integer or floating point kinds. For example, operators like +, -, *, / and % get arithmetic expressions as their operands and generate arithmetic values as their outcomes.

  • Q : Assembly program that reads in five

     I need to write assembly program that reads in five numbers from the user. The user can then be prompted for one of the following pieces of information to be computed and returned: . the mean of the five numbers; . the largest number in the set; . the smallest number in the set; . t

  • Q : Explain Throw statement Throw statement

    Throw statement: It is a statement employed to throw an exception. For example:     throw new IndexOutOfBoundsException(i+" is too large.");

  • Q : What do you mean by process What do you

    What do you mean by the term process? Illustrate briefly.

  • Q : What is Bit Bit : It is a binary digit

    Bit: It is a binary digit that can take on two possible values: 0 and 1. The bits are basic building block of both data and programs. Computers regularly shift data around in multiples of eight-bit units (that is, bytes for the sake of effectiveness).

  • Q : Explain functionality or an API needs

    The application I am creating needs having access to functionality or an API that use needs the Nokia Vendor ID. For my application how can I have this Nokia VID?

  • Q : "This" Pointer "this" pointer: In C++

    "this" pointer: In C++ uses a unique keyword called "this" to represent a object that

©TutorsGlobe All rights reserved 2022-2023.