[erlang-questions] Re: command-line args in erl

Jordan Wilberding diginux@REDACTED
Fri Apr 16 02:34:59 CEST 2010


Yep!

'anything in single quotes even with spaces is an atom'
"in double quotes it is a string"

For more info: http://www.erlang.org/doc/reference_manual/data_types.html

JW

On Thu, Apr 15, 2010 at 4:41 PM, Wes James <comptekki@REDACTED> wrote:

> On Thu, Apr 15, 2010 at 3:25 PM, Wes James <comptekki@REDACTED> wrote:
>
> <snip>
>
> >
> > and this code:
> >
> > main(WArg,HArg) ->
> >  W = WArg, %list_to_integer(atom_to_list(WArg)),
> >  H = HArg, %list_to_integer(atom_to_list(HArg)),
>
> hmm, interesting.
>
> erl....
>
> A='200'
> '200'
> B=atom_to_list(A).
> "200"
> C=list_to_integer(B).
> 100
>
> atom is in single quote and list is in double quote??
>
> -wes
>
> ________________________________________________________________
> erlang-questions (at) erlang.org mailing list.
> See http://www.erlang.org/faq.html
> To unsubscribe; mailto:erlang-questions-unsubscribe@REDACTED
>
>


More information about the erlang-questions mailing list