There's nothing special about letters verses punctuation in the above
code. Are you talking about the quotes that surround the string; i.e.,
string = "this is a string" ?
Have you escaped the double-quotation mark " with a back-splash like "I
escape the \" with a back splash" ? Or, you can try other delimiters
like quotation mark ' or use a word array instead, like %w{this is an
word array}.
1. I'd not call arrays "strings". It's confusing. "newString" isn't a
string here.
2. Why is "string[length]" surrounded by "[]" ? This creates an array
of 1-element arrays. Is this what you want?
3. you first take the element string[string.length]. This is nil. Is
this what you want?
On Thu, Jun 14, 2012 at 07:08:33PM +0900, Scott W. wrote:
Have you escaped the double-quotation mark " with a back-splash like "I
escape the \" with a back splash" ? Or, you can try other delimiters
like quotation mark ' or use a word array instead, like %w{this is an
word array}.