Evaluation and Variables


<p>
<php echo 1; ?>
</p>

<p>
<php echo 1 + 2; ?>
</p>

<p>
<php echo 2 * 3; ?>
</p>

<p>
<php echo 10 / 2; ?>
</p>

<p>
<php echo 10 / 3; ?>
</p>

<p>
<php echo 1 + 2 * 5; ?>
</p>

<p>
<php echo ( 1 + 2 ) * 5; ?>
</p>

<p>
<?php
    $a = 10;
    echo 2 * $a;
?>
</p>

<p>
<?php
    $a = 10;
    $b = 2;
    echo $b * $a;
?>
</p>

<p>
<?php
    echo "Hello, World";
?>
</p>

<p>
<?php
    $a = "Rose";
    echo "Hello, ";
    echo $a;
?>
</p>

<p>
<?php
    $a = "Rose";
    echo "Hello, " . $a;
?>
</p>

<p>
<?php
    $a = "Rose";
    $b = "Hello, " . $a;
    echo $b;
?>
</p>

<p>
<?php
    $a = "Rose";
    $b = "Hello, $a";
    echo $b;
?>
</p>

<p>
<?php
    $a = "Rose";
    $b = "Hello, \$a";
    echo $b;
?>
</p>

<p>
<?php
    $a = 100;
    $b = "The price is \$$a";
    echo $b;
?>
</p>

<?php
    $a = 100;
    $b = "The price is \$$a";
    echo "<p>";
    echo $b;
    echo "</p>";
?>

<?php
    $a = 100;
    $b = "The price is \$$a";
    echo "<p>$b</p>";
?>