IT学习者 -> 技术文档 -> PHP 完全中文手册

函数:mhash_count()


mhash_count

取得哈稀 ID 的最大值。

语法: int mhash_count(void);

返回值: 整数

函数种类: 编码处理

内容说明

本函数用来取得哈稀演算的最大 ID 值。在使用哈稀计算时,会从 0 开始计数到使用的数值。本函数不用输入参数。

使用范例

<?php
$nr 
mhash_count();
for(
$i 0$i <= $nr$i++) {
  echo 
sprintf("哈稀 %s 的区块大小为 %d\n"mhash_get_hash_name($i), mhash_get_block_size($i));
}
?>



[ 上一页  PHP中文手册  下一页 ]

PHP 首页 | PHP 导读 | PHP 函数库 | PHP 函数索引 | PHP 范例程序