Predefined Type Taxonomy - CSharp Language Basics

CSharp examples for Language Basics:Data Type

Introduction

The predefined types in C# are:

Value types

Numeric
  Signed integer (sbyte, short, int, long)
  Unsigned integer (byte, ushort, uint, ulong)
  Real number (float, double, decimal)

Logical (bool)
Character (char)

Reference types

  • String (string)
  • Object (object)

Predefined types in C# alias Framework types in the System namespace.

There is only a syntactic difference between these two statements:

int i = 5;
System.Int32 i = 5;
     

Related Tutorials