...
Code Block |
---|
signed int si1, si2, result; signed long long tmp = (signed long long)si1 * (signed long long)si2; /* * If the product cannot be repesented as a 32-bit integer * then handle as an error condition */ if ( (tmp > INT_MAX) || (tmp < INT_MIN) ) { /* handle error condition */ } result = (int)tmp; |
...
- Seacord 05 Chapter 5 Integers
- Warren 02 Chapter 2 Basics