Hello,
I need to generate data for an application which only accept localized data, and refuse a float using a dot as separator.
I can write a function like this one:
let format_float
: float -> string
= fun f ->
String.concat "," (String.split_on_char '.' (Float.to_string f))
but I would like if there is a simple way to do the same, either with a dedicated library, or with printf
trick that I’m not aware of. Do you have a nice solution for that ?
Thanks !