Code archives/Algorithms/Decimal to the length of the binary equivalent
This code has been declared by its author to be Public Domain code.
Download source code
| |||||
It just uses maths which is good, and it is also optimised. it used to use a division instead of a multiplication. | |||||
Function BinaryLength(dec) Return Ceil(Log(dec)*1.4427) End Function |
Comments
None.
Code Archives Forum