当前位置:首页 > 开发 > C# > 正文内容

C# 数据类型

C#4年前 (2021-12-18)
Type ByteLenghtMinMax.NET Framework Typedefault
bool4FALSETRUESystem.BooleanFALSE
sbyte1-128127System.SByte0
bytet20255System.Byte0
short2-3276832767System.Int160
ushort2065535System.UInt160
int4-21474836482147483647System.Int320
uint404294967295System.UInt320
long8-92233720368547758089223372036854775807System.Int640L
ulong8018446744073709551615System.UInt640
float4±1.5e−45±3.4e38(精度7位)System.Single0.0F
double8±5.0e−324±1.7e308(精度15-16位)System.Double0.0D
char
U+0000U+ffffSystem.Char/0
string


System.String
object


System.ObjectNULL
decimal


System.Decimal


转载请注明出处。

本文链接:http://www.pythonopen.com/?id=171

相关文章

C# 模拟按键

方法1SendKeys.SendWait("123{TAB}abc");&nbs...

C# 时间操作

获取系统已运行时间    System.Environment.Tic...

C# 计算平年闰年

一个年份整除4取余,如果有余数,则为平年,如果没有余数,则是闰年。但如果是这个年份是100的倍数,则...

C# 跳出foreach循环

在 C# 中,如果你想在 foreach 循环内部提前跳出当前这一轮循环,继续执行下一轮循环,可以使...

C# 缩减代码量的一些方式

static void Main() { Thread thre...

C# decimal

概述在 C# 中,decimal是一种数据类型,用于表示高精度的十进制数值。它主要用于需要精确计算的...