Re: Questions from a Beginner.
- Posted by doncole2009 May 28, 2009
- 929 views
Hey,
Thanks to whoever cleared the gargabe out of this thread.
Just a small question for anybody who can answer:
The short version is: how do I convert ascii text in a sequence to numerical atoms in a sequence?
Here's the long version
I'm trying to compare parts of two sequences.
An example of the first sequence would be something like {E,0,0}
The second would be something like { {70,0,0}, {69,0,0}, {68,0,0} }
I can't seem to get EU to recognize that sequence 1 is equal to the second sequence of sequence 2 (I thought it might see it as equal because the ascii code for "E" is 69)
So I'm assuming I need to convert the ascii value to an atom value. How do I do this?
An example of the first sequence would be something like {E,0,0}
The second would be something like { {70,0,0}, {69,0,0}, {68,0,0} }
key="E" printf(1,"ascii=%d\n",{key})
First you must determine if the values should be converted or not. What about the 2 0s?
The best thing is to make sure your sequences have like values before you compare.
Don Cole