So I want to check if someone enters: \\n (\'\\\' and then \'n\') from the keyboard to a string, so I\'m doing something like this:
\\n
\'\\\'
\'n\'
if user enter like \ and n using keyboard .
\
n
then try like this
if(str[i] == '\\' && str[i+1] == 'n')
As \ is represented by \\, so use \\ instead of \ to check.
\\