what is the difference between \n and \r\n in c#

What is the difference between \n and \r\n in c#

This type character use for new line.

 \r\n is Windows, \n is Unix, \r is Mac.

\r\n = CR + LF // Used as a new line character on Windows

\n = LF (Line Feed) // Used as a new line character on Unix

\r = CR (Carriage Return) // Used as a new line character on Mac

(char)13 = \r = CR

2020-04-22