Difference between Serial.println(""), Serial.println('') and Serial.println()?

Hello,

I came across these 3 ways to insert a blank line in-between Serial.print texts and i'm wondering what distinguishes them, if any?

Serial.println("")
Serial.println('')
Serial.println()

If you have nothing between the single or double quotation marks then all 3 will do the same and simply move to the next line

Note that none of them actually prints a blank line

Do you want another way to move to the next line to add to your collection ?

Serial.print("\n");

If you really want a blank line you can do

Serial.println("\n");
  1. Serial.println(""): Prints an empty string and then calls println() to write "\r\n"
  2. Serial.println(''): Is invalid (empty character literal is a syntax error)
  3. Serial.println(): Writes "\r\n"

Pieter

Note my mistake about the empty character