logo       

string conversion, format functions: msg#00336

lang.erlang.general

Subject: string conversion, format functions

I have a string "123" and want to convert it to an integer
or float, and vice versa.

In python, I go to the string module and
there are string.atoi(), string.atof(), and str(number).
So, by habit, I went to string module doc in Erlang
I could not find the counterparts of these functions. Where are they ?

-------------------------
B = 3.

I want to form a string "0003".
** Can io:format generate such a printout ?
** Can it be redirected to a string ?
** If not, how do folks in Erlang world do this padding?

thanks,
hp




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise