Click here to get back home

How to display 1.234.567.890,00 from 1234567890 ?

 HomeNewsGroups | Search | About
 comp.lang.perl.misc    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
How to display 1.234.567.890,00 from 1234567890 ? Jason Stacy 05-05-2008
Get Chitika Premium
Posted by Jason Stacy on May 5, 2008, 2:33 am
Please log in for more thread options
Given a decimal value (e.g. 1234567890) I want to print this number with
grouping delimiters (european style with dots: 1.234.567.890,00
and not US style 1,234,567,890.00)

How can I do this in perl?

Jason


Posted by sheinrich on May 5, 2008, 3:30 am
Please log in for more thread options
On May 5, 8:33 am, jjst...@yahoo.net (Jason Stacy) wrote:
> Given a decimal value (e.g. 1234567890) I want to print this number with
> grouping delimiters (european style with dots: 1.234.567.890,00
> and not US style 1,234,567,890.00)
>
> How can I do this in perl?
>
> Jason

Adapt any of the methods given at
http://faq.perl.org/perlfaq5.html#How_can_I_output_my_

BTW: the comma as a decimal separator is country _and_ language
specific, and is not common across europe.


Posted by Jürgen Exner on May 5, 2008, 9:42 am
Please log in for more thread options
jjstacy@yahoo.net (Jason Stacy) wrote:
>Given a decimal value (e.g. 1234567890) I want to print this number with
>grouping delimiters (european style with dots: 1.234.567.890,00
>and not US style 1,234,567,890.00)
>
>How can I do this in perl?

See perldoc -q added

Replacing the comma with a dot in the sub commify() is left as an
excercise to the reader.

jue

Similar ThreadsPosted
I need to display pdf. August 8, 2007, 1:03 pm
How to display a pdf file using CGI April 14, 2006, 6:00 pm
64 Bit integer display March 20, 2008, 4:04 pm
IE Doesn't Display Romanian Page! February 23, 2005, 11:30 pm
SYstem wait display March 28, 2005, 10:51 am
Text display like table August 23, 2005, 10:25 am
Help with a pagraph to be display as a one big line October 17, 2005, 10:08 am
how to check whether Display variable is set or not March 9, 2006, 7:05 am
How to display image from RAM with some text around April 28, 2006, 9:29 am
display datestamp in HTML March 2, 2007, 11:40 am

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap