Decimal C# là gì

This information refers to fixed-point decimal data types as decimal data types. The decimal data type is an extension of the ANSI C language definition. When using the decimal data types, you must include the decimal.h header file in your source code. That header file specifies the value of DEC_DIG, which sets the maximum length allowed for expressions, in significant digits, including integral and fractional parts.

Decimal data types are available only if the LANGLVL is EXTENDED by specifying the LANGLVL[EXTENDED] compiler option. For more information, see LANGLVL in z/OS XL C/C++ User's Guide.

You can use decimal data types to represent large numbers accurately, especially in business and commercial applications for financial calculations. You can pass decimal arguments in function calls and in define macros. You can also declare decimal variables, data type definitions, arrays, structures, and unions that have decimal members.

When you use decimal variables, the following operators apply:

Video liên quan

Chủ Đề