Hi
A very common problem people come-up with while working with string data type is how to work with special character. A number of characters have been labeled as special characters. How would you represent a quote within a string, since the compiler interprets a quote as the beginning or end of the string? Whenever you want to use one of these special characters you need to use a technique known as escaping the character.
Here is a list of the string that needs to be used for the purpose of this special character.
\n = New Line
\r = Carriage return
\r\n = Carriage return and New line
\” = Quotation mark
\\ = Backlash character
\t = Tab
[Note: Even though escaped characters involve two characters (backslash \ plus the escaped character) the compiler treats the sequence as one character. That means that \n is a single character and the same is true for \", \\, etc]
Hope this helps
Thanks
Vikram