English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

decoct() function in PHP

Thedecoct()The function converts a decimal number to an octal. It returns the octal string of the specified decimal.

Syntax

decoct(num)

parameter

  • num-the decimal value to be converted.

returns

Thedecoct()The function returns the octal string of the specified decimal.

Example

<?php
   echo decoct("70");
?>

Output Result

106

Let's see another example-

Example

<?php
   echo decoct("7878787888");
?>

Output Result

72547141460