系統(tǒng)預(yù)定義類型
類型 | 描 述 | 范圍/精度 | 例子 |
object | 所有其它類型的最根本的基礎(chǔ)類型 | object o = null; | |
string | 字符串類型,一個字符串是一個Unicode字符序列 | string s= "Hello"; | |
sbyte | 8-bit 有符號整數(shù)類型 | –128...127 | sbyte val = 12; |
short | 16-bit有符號整數(shù)類型 | –32,768...32,767 | short val = 12; |
int | 32-bit有符號整數(shù)類型 | –2,147,483,648...2,147,483,647 | int val = 12; |
long | 64-bit有符號整數(shù)類型 | –9,223,372,036,854,775,808 ...9,223,372,036,854,775,807 | long val1 = 12; long val2 = 34L; |
byte | 8-bit無符號整數(shù)類型 | 0...255 | byte val1 = 12; byte val2 = 34U; |
ushort | 16-bit無符號整數(shù)類型 | 0...65,535 | ushort val1 = 12; ushort val2 = 34U; |
uint | 32-bit無符號整數(shù)類型 | 0...4,294,967,295 | uint val1 = 12; uint val2 = 34U; |
點擊加載更多評論>>