search

Home  >  Q&A  >  body text

ternary operator

<?php

$arry=[ ]

?>

NimmbNimmb2488 days ago1477

reply all(1)I'll reply

  • sky

    sky2018-03-13 18:09:24

    <?php

    $a = TRUE;


    echo $a?'1':'2'; // Output 1

    ?>


    reply
    0
  • Cancelreply