<?php
$welcome = 'Hello';
$world = 'World';
// Solution 1
$msg = $welcome . ', ' . $world . ' !';
// Solution 2
$msg = "$welcome, $world !";
echo $msg;
echo '<br>';
/* --- 0 && null --- */
echo '0 == null => ';
if(0 == null) {
echo 'yes';
} else {
echo 'no';
}
echo '<br>';
echo '0 === null => ';
if(0 === null) {
echo 'yes';
} else {
echo 'no';
}
/* --- ' ' && 0 --- */
echo '<br>';
echo '\' \' == 0 => ';
if(' ' == 0) {
echo 'yes';
} else {
echo 'no';
}
echo '<br>';
echo '\' \' === 0 => ';
if(' ' === 0) {
echo 'yes';
} else {
echo 'no';
}
echo '<br>';
/* --- ' ' && null --- */
echo '\' \' == null => ';
if(' ' == null) {
echo 'yes';
} else {
echo 'no';
}
echo '<br>';
echo '\' \' === null => ';
if(' ' === null) {
echo 'yes';
} else {
echo 'no';
}
?>