This website requires JavaScript.
Explore
Help
Sign In
Discharge7443
/
Hexo-Butterfly
Watch
1
Star
0
Fork
0
Code
Issues
Pull Requests
Actions
Packages
Projects
Releases
Wiki
Activity
Files
01423219b7526ad45c188e88f7b5bfd20cbff964
Hexo-Butterfly
/
source
/
_posts
/
Binary-Search.md
T
Leon Xu
2ac3b9ce03
doc: update binary search working theory
2021-07-07 10:58:02 -07:00
511 B
Raw
Blame
History
title, date, tags
title
date
tags
Binary Search(二分搜索)
2021-07-07 10:31:20
算法
二分搜索
什么是二分查找算法?
二分搜索是一种算法;它的输入是一个已排序的元素列表。如果你要找的元素在这个列表中,二分查找返回它所在的位置。否则,二进制搜索返回
null
。
下面的示例说明了二分查找的工作原理。我随便想一个1~100的数字。
Reference in new issue
View Git Blame
Copy Permalink