Site icon DataFlair

PHP String Concatenation

Program 1

<html>
    <head><title>String Operator in PHP</title>
    <body>
     <center>
  
<?php
    //  $a=50;
    //  $b=30;
    //  $c=$a+$b;
    //  echo "Addtion of  ".$a." and ". $b. " is ".$c 
     $x="Data";
     $y="  Flair Free Course";
     $x.=$y; 
     echo $x;

       /* 
          a=70 , b 30   //   grater between 70 and 30 is 70
       */
?>
</center>
</body>
</html>

 

Exit mobile version