diff options
author | Joel Kronqvist <joelkronqvist@proton.me> | 2024-04-07 10:53:40 +0300 |
---|---|---|
committer | Joel Kronqvist <joelkronqvist@proton.me> | 2024-04-07 10:53:40 +0300 |
commit | f975594e55bdc05ee436bc7bdcd6e09aec5357b1 (patch) | |
tree | e1ddb07ab967bbe9eb6a14865e7413b9b2e1ea0c /intmath.h | |
parent | 1ef526c695df4b37aa184867fb5b62c93118aa02 (diff) | |
download | stdu-f975594e55bdc05ee436bc7bdcd6e09aec5357b1.tar.gz stdu-f975594e55bdc05ee436bc7bdcd6e09aec5357b1.zip |
Finished implementation for formatting for human readability
Diffstat (limited to 'intmath.h')
-rw-r--r-- | intmath.h | 29 |
1 files changed, 1 insertions, 28 deletions
@@ -1,33 +1,6 @@ - -#ifndef INTMATH_IS_IMPORTED -#define INTMATH_IS_IMPORTED - -struct exp_val { - int mantissa; - int exponent; - int base; -}; -typedef struct exp_val exp_notated; - +int int_pown(unsigned int base, unsigned int exp); int int_pow10(unsigned int exp); int int_floor(int x, int precision); int int_ceil(int x, int precision); int int_max(int a, int b); int int_min(int a, int b); -exp_notated int_floored_exponent_notation_base( - int x, - unsigned int precision, - unsigned int base -); -exp_notated int_ceiled_exponent_notation_base( - int x, - unsigned int precision, - unsigned int base -); -exp_notated int_floored_exponent_notation(int x, unsigned int precision); -exp_notated int_ceiled_exponent_notation(int x, unsigned int precision); -int exp_notated_to_int(exp_notated x); -const char* binary_prefix(exp_notated x); -char* int_floored_with_binary_prefix(int x); - -#endif |