From: Gavin Sinclair Date: 2003-12-09T05:55:07+09:00 Subject: Re: format money On Tuesday, December 9, 2003, 6:07:02 AM, saggmannen wrote: > Hello, is there a way to format "Money"-style floats in ruby. E.g: > 2111000.5756 should be written as the string "2,111,000.58" > Maybe even more configurable with the Money-style class even taking > locale into account, or at least letting the user define what kind of > tokens to use as thousand-separator and decimal-token. This can be > done in C++ (even if it's kind of complicated). Has it been done in > ruby? http://extensions.rubyforge.org defines Numeric#format_s (originally written by Austin Ziegler) which gives you control over the characters used for separator, and everything else. Gavin