<?Php
echo dechex(2); // Output 2
echo "<br>";
echo dechex(25); // Output 19
echo "<br>";
echo dechex(200); // Output is c8
echo "<br>";
echo dechex(358); // Output is 166
echo "<br>";
echo dechex(2000); // Output is 7d0
?>
Syntax
string dechex(int $number);
Parameter | DESCRIPTION |
---|---|
$number | Required : Decimal number as Input to convert to equivalent hexadecimal number. |