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

PHPのbindec()関数

このbindec()関数は二進数を十進数に変換します。

構文

bindec(bin_str)

引数

  • bin_str-変換する二進数文字列

返します

このbindec()関数は指定された文字列の十進値bin_strを返します

<?php
   echo bindec("1101");
?>

出力結果

出力表示しますbindec()関数は十進値を返します:

13
基本チュートリアル