03 2022 档案
摘要:/** * 快速排序 */ function quickSort($list) { if (count($list) < 2) { return $list; } else { $privot = $list[0]; $left = []; $right = []; for ($i = 1; $i
阅读全文
摘要:/** * 选择排序 */ function findSmallest($list) { $small = $list[0]; $k = 0; foreach ($list as $key => $value) { if ($value <= $small) { $small = $value; $
阅读全文
摘要:数组在内存中是一群连续的地址,而链表可以不连续,上一个元素会存储着下一个元素的地址。 因此链表适合插入和删除操作比较多的数据,数组适合经常需要随机访问的数据。、 FaceBook存储用户名的方式既不是数组也不是链表,而是一种混合数据,链表数组。假设其数据是按照用户名存储的,那么这个数组包含26个元素
阅读全文
摘要:/** * 二分查找(有序序列) */ function binaryAlgorithm($list, $item){ $low = 0; $high = count($list) - 1; while ($low <= $high) { $mid = floor($low + $high) / 2
阅读全文
摘要:PHPUNIT http://www.phpunit.cn/manual/current/zh_cn/phpunit-book.pdf
阅读全文
摘要:修改镜像源命令 composer config -g repo.packagist composer 阿里云 Composer 全量镜像 镜像地址:https://mirrors.aliyun.com/composer/ 官方地址:https://mirrors.aliyun.com/compose
阅读全文

浙公网安备 33010602011771号