Re: [PHP3] Fractions
| From: | Matthew Kendall | Date: | Fri, 09 Jun 2000 21:12:32 +0000 |
| Subject: | Re: [PHP3] Fractions | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-1446@lists.php.net to get a copy of this message | ||
"Thierry Coopman" <calvin@skynet.be> wrote ...
> I was wondering if it was possible to convert regular numbers
> with decimals like 87.875 to the equivalent with fractions
> (like those used in stock exchanges).
If it is stock prices that you are concerned with then you don't need a
general algorithm. There are only a handful of possibilities. You could just
use a simple lookup table.