Php - Simple if else code reduce coding lines, If else statement


Simple if else code reduce coding lines

In general we write if else as
if($a) {
 print $b;
}
else {
 print $c;
}

Reduce the if else code by ? :
  print ( $a ? $b : $c );

Php - If else statement
The topic on Php - Simple if else code reduce coding lines is posted by - Malu
Hope you have enjoyed, Php - Simple if else code reduce coding lines . Thanks for your time.

All rights reserved. © www.w3calculator.com