RE: [PHP-ES] Aproximar resultado
| From: | Leonel Quinteros | Date: | Thu, 01 Mar 2007 23:57:31 +0000 |
| Subject: | RE: [PHP-ES] Aproximar resultado | ||
| Groups: | php.general.es | ||
| Request: | Send a blank email to general-es+get-60536@lists.php.net to get a copy of this message | ||
Si, con la funcion round():http://www.php.net/manual/es/function.round.phpSaludosLeonel>
Date: Thu, 1 Mar 2007 15:15:41 -0300> From: fodsite@gmail.com> To: php-es@lists.php.net>
Subject: [PHP-ES] Aproximar resultado> > Hola amigos me gustaria saber si es posible aproximar
un resultado que> viene de una operacion matematica.> > ej:> > 2120 / 2229 =
0.95109> > 0.95109 * 100 = 95.1099 %> > ¿como podria dejar este resultado de la forma
95.11 % ?> > es decir, aproximar el valor y dejar solo y nada mas que 2 decimales.> >
Saludos> > -- > Luis Vega M.> Linux Registered User #356394 - counter.li..org> Sitio
Personal: http://fodsite.webcindario.com> Green Day:
http://www..greendayfod.net> <fodsite AT gmail DOT
com>> > -- > PHP Spanish Localization Talk Mailing List (http://www.php.net/)> To
unsubscribe, visit: http://www.php.net/unsub.php>
_________________________________________________________________
Descubre Live.com - tu mundo en línea reunido: noticias, deportes, el tiempo, y mucho más.
http://www.live.com/getstarted