Binary search: Difference between revisions
→{{header|Minimal BASIC}}: Corrected. Minimal BASIC does not have the operators OR, AND, NOT.
Thundergnat (talk | contribs) m (Automated syntax highlighting fixup (second round - minor fixes)) |
(→{{header|Minimal BASIC}}: Corrected. Minimal BASIC does not have the operators OR, AND, NOT.) |
||
Line 1,608:
{{works with|Commodore BASIC|3.5}}
{{works with|Nascom ROM BASIC|4.7}}
<syntaxhighlight lang="
10 REM Binary search
20 LET N = 10
Line 1,640:
520 LET F = 0
530 LET M = L
540 IF L > H
550
560
570
580
590 GOTO 540
600
610
620
630
640
650
660
670
680
690 RETURN
</syntaxhighlight>
=={{header|BASIC256}}==
====Recursive Solution====
|