Binary search: Difference between revisions
m
→{{header|Chapel}}
(Add bruijn) |
LalaithMeren (talk | contribs) |
||
Line 2,891:
'''iterative''' -- almost a direct translation of the pseudocode
<syntaxhighlight lang="chapel">proc binsearch(A : [], value)
{
var
while (low <= high)
{
var mid = (low + high) / 2;
Line 2,911 ⟶ 2,913:
{{out}}
4
=={{header|Clojure}}==
'''Recursive'''
|