php实现随机点名程序
- 作者: 亖呉?盀
- 来源: 51数据库
- 2022-08-23
- 用的是mt_random()函数(性能优于random()函数)
<?php
$max1=51;
$min1=1;
$stu=mt_rand($min1,$max1);
if($stu>26)
{
$stu=$stu-25
echo '2014585032'.$stu.'号同学';
}
else
{
echo '2014585031'.$stu.'号同学';
}
?>
推荐阅读
