Introducing Data Types

Data is stored in memory locations. These storage locations, which can either be variables or constants, are represented by an alphanumeric combination in the internal memory of the computer. For example, ccc0088975 can be an address in the computers internal memory. However, it is more difficult to remember numbers than names. So, to make life easier, names are assigned to each of these storage locations. The kind of data that can be placed in these variables depends on the type of the variable. C# supports most of the common data types found across all programming languages. These data types can be classified into three main categories: value, reference, and pointer types, as shown in Figure 5.1.

Figure 5.1. Types are ...

Get Special Edition Using C# now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.