You could roll your own...

% and (int) / and round() are all you need.


--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out?  Like Music?  Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
----- Original Message -----
From: Bill Rausch <[EMAIL PROTECTED]>
Newsgroups: php.general
To: <[EMAIL PROTECTED]>
Sent: Wednesday, October 03, 2001 10:40 AM
Subject: printf scientific notation?


> I'll try this again, with a new topic and a better description.
>
> Can PHP print floating point numbers using scientific notation?
> (like 1.32e+5) sscanf reads them ok using %f, but I'd like to print
> them with %e or %g and the printf documentation doesn't mention them.
>
> I've tried %e anyway and it fails to print the exponent part.
>
> I've looked at the source code to PHP a little but with the IFDEFs
> I'm not sure which routine is actually being used. I sort of have the
> impression it is just calling the C routines directly so the %e and
> %g should work?
>
> Linux (RH 7.1), Apache (1.3.20), PHP (4.0.6)
>
> Thanks.
> --
>   Bill Rausch, Software Development, Unix, Mac, Windows
>   Numerical Applications, Inc.  509-943-0861   [EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to