initialize then output in single line
<p><strong>PHP</strong></p>

<pre><code>&lt;?php 
    $x = 10; 
    echo $x = 20;
?&gt;
</code></pre>

<p><br/>
<strong>c++</strong></p>

<pre><code>#include&lt;iostream&gt;
using namespace std;

int main(){

    int x = 10;

    cout &lt;&lt; x = 20;

    return 0;

}
</code></pre>

<p>Why in php initialize then ouput in a single line works, in c++ it didnt work?</p>
