Data types present in DOT NET

List the types of data types that are present in .NET?

E

Expert

Verified

The two types of data types that are existed in .NET are as follows:

1. Value type – It refers to data type which contains the data. Or we can say, the exact value or data is directly stored in this data type. This means that when we assign the value type variable to other variable, then it copies value rather than copying reference of variable. When we produce value type variable, a single space in memory is allotted to store value (stack memory). Primitive data types are examples of value type variables like int, float, and char.

2. Reference type – It refers to a data type which could access data by reference. Reference is a value or the address which accesses particular data by address that is stored somewhere else in memory (heap memory). We can say that reference is a physical address of data, where the data is stored in the memory or in a storage device. Built-in reference types variables in .Net like string, array, and object.

   Related Questions in DOT NET Programming

©TutorsGlobe All rights reserved 2022-2023.