Integral Types Table (C# Reference)
This page is specific to:.NET Framework Version:1.12.03.03.54.0
C# Language Reference
Integral Types Table (C# Reference)

The following table shows the sizes and ranges of the integral types, which constitute a subset of simple types.

Type

Range

Size

sbyte

-128 to 127

Signed 8-bit integer

byte

0 to 255

Unsigned 8-bit integer

char

U+0000 to U+ffff

Unicode 16-bit character

short

-32,768 to 32,767

Signed 16-bit integer

ushort

0 to 65,535

Unsigned 16-bit integer

int

-2,147,483,648 to 2,147,483,647

Signed 32-bit integer

uint

0 to 4,294,967,295

Unsigned 32-bit integer

long

-9,223,372,036,854,775,808 to 9,223,372,036,854,775,807

Signed 64-bit integer

ulong

0 to 18,446,744,073,709,551,615

Unsigned 64-bit integer

If the value represented by an integer literal exceeds the range of ulong, a compilation error will occur.

See Also

Concepts

Reference

Other Resources

© 2009 Microsoft Corporation. All rights reserved.   Terms of Use | Trademarks | Privacy Statement
Page view tracker
Rate the Lightweight library
x
Lightweight builds on ScriptFree (loband) by adding features you've requested: a SearchBox and default code language selection.
Do you like the SearchBox?
Do you like the tabbed code blocks?
How useful is this topic?
Tell us more.
Thanks
x
You're helping to improve MSDN Online.
Feedback
Switch View
Classic
Lightweight Beta
ScriptFree
Switch View