问号是什么?"十进制?"意思?

时间:2013-12-19 08:04:52

标签: c#

我正在关注有关MVC4 asp.net的教程。教程正在使用Decimal,如下所示:

     public Decimal x{ set; get; }
     public Decimal? y{ set; get; }

?

之后使用Decimal时的含义是什么

1 个答案:

答案 0 :(得分:7)

这意味着所讨论的值类型是可以为空的类型

见这里

What is the purpose of a question mark after a type (for example: int? myVariable)?