F#入门-附录1 基本数据类型

来源:互联网 发布:python unicode 去掉u 编辑:程序博客网 时间:2024/04/28 04:57
基本数据类型
参考
                  The F# 1.9.6 Draft Language Specification
                           6.4.1 Simple constant expressions
                           16.1.1 Basic Type Abbreviations
   
         obj             = System.Object    : new obj()
         exn             = System.Exception : System.Exception()
         nativeint       = System.IntPtr    : 10n
         unativeint      = System.UIntPtr   : 10un
         string          = System.String    : "abc","你好"
         float32, single = System.Single    : 3.14f
         float, double   = System.Double    : 3.14,1.4e5
         sbyte           = System.SByte     : 10y
         byte            = System.Byte      : 10uy
         int16           = System.Int16     : 10s
         uint16          = System.UInt16    : 10us
         int32, int      = System.Int32     : 10
         uint32          = System.UInt32    : 10u
         int64           = System.Int64     : 10L
         uint64          = System.UInt64    : 10UL
         char            = System.Char      : '7'
         bool            = System.Boolean   : true或false
        decimal          = System.Decimal   : 10M
        其他(byte文字) char[] : "ABC"B
原创粉丝点击