Declaring _DecimalT Class Template Objects
To declare an object as a
_DecimalT class template:
_DecimalT<10,2> x;
_DecimalT<5,0> z;
_DecimalT<18,10> *ptr.;
_DecimalT<8,2> arr[100]; Note:
- The variable
xcan have values from__D("-99999999.99")to__D("+99999999.99") - The variable
zcan have values from__D("-99999")to__D("+99999") ptris a pointer to an object of type_DecimalT<18,10>arris an array of 100 elements, where each element is of class_DecimalT<8,2>- Leading zeros show the size of the number of digits in the
_DecimalTclass templates. You do not need to enter leading zeros in your_DecimalTclass templates.