how to print text and variable's values in the same line with Serial.println in Arduino
<p>I've this code:</p>

<pre><code> Serial.print("x:");
 Serial.print(x);
 Serial.print(" y: ");
 Serial.println(y);
</code></pre>

<p>and works fine. There's an example of the output:</p>

<pre><code>x:41 y: 31
</code></pre>

<p>but I wonder if there's a way to write the four sentences in one with something like:</p>

<pre><code>Serial.println("x:"+x+" y:"+y);
</code></pre>

<p>that returns an error: </p>

<pre><code>invalid operands of types 'const char*' and 'const char [4]' to binary 'operator+'
</code></pre>

<p>Any idea?. Thanks in advance.</p>