Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Re: escaping characters?

From: gscottjones:mchsi at: 10-Mar-2002 8:54

From: "Adrian"
> Hello, > I`m new to Rebol and I have a simple question. I don`t seem to > be able to find the answer to. > How do you print quotes? I tried print ""hello"" print "\"hello\"" and > others. Is there a way to escape characters like you do in C and other > languages. Also newlines (\n) . Any input is appreciated.
Hi, Adrian, The "carrot" is the escape character and can be used like so:
>> print "^"Hello^""
Hello Or using curly braces negates the need to escape the double quotes:
>> print {"Hello"}
Hello Carrot slash (^/) is the return/newline sequence and it is translated correctly in each platform:
>> print {"Hello"^/"Goodbye"}
Hello Goodbye Hope that answers the questions. --Scott Jones