Reputation: 55323
For some reason, I couldn't find this information anywhere.
Let's say I have some dummy text:
Line 1
Line 2
Line 3
What would be the difference between matching \n
and \n\n
?
Is it like this?
Line 1\n
\n
Line 2
Line 3
Or like this?
\nLine 1
\n
Line 2
Line 3
Or like this?
Line 1
\n
\n
Line 2
Line 3
Upvotes: 0
Views: 54
Reputation: 526
it should be straight forward, one \n
means one new line, two \n\n
means two new lines, depends on use cases if you want to remove all newlines in text just use \n+
Upvotes: 5