Binary

Binary has several distinct usages:

  • binary integers: a way to represent numbers with 0 and 1

  • binary operators: operators that use 2 arguments

  • binary search: a search technique over a sorted array

  • binary executable: the compiled version of PHP, not as source code

Generally, binary refers to the binary integers.

<?php

    // 12 in binary
    $binary = 0b1100;

    // > is a binary operator: it takes 2 arguments
    var_dump($binary > 13);

?>

Related : Binary Integer, Binary Operator, PHP Runtime, Base