CS 2114 Lecture Notes - Lecture 24: Binary Search Algorithm, Mobile Suit Gundam

62 views1 pages
Daniel T. Eisert CS-2114
1
Lecture 24 Binary Search
April 16, 2018 (Week 13)
Class Business
Project V final submission is due Thursday, April 26. The contribution report
and ethics discussion are both due Sunday, April 29.
Last lab session is Wednesday, April 25.
OpenDSA Homework on Trees is due Monday, April 30.
Efficiency of
Searching
- Major efficiency jump compared to using a loop / using contains.
-  in computer science refers to base 2 (Recall ~   ).
- MUST have a sorted array for binary search.
Iterative or
Recursive Search
- Can save some time and space by using iterative version of a search.
- Using recursion will not require much additional space for recursive
calls.
- Coding binary search recursively is somewhat easier.
find more resources at oneclass.com
find more resources at oneclass.com
Unlock document

This preview shows half of the first page of the document.
Unlock all 1 pages and 3 million more documents.

Already have an account? Log in

Document Summary

Project v final submission is due thursday, april 26. The contribution report and ethics discussion are both due sunday, april 29. Opendsa homework on trees is due monday, april 30. log in computer science refers to base 2 (recall ~ 2=2). Major efficiency jump compared to using a loop / using contains. Must have a sorted array for binary search. Can save some time and space by using iterative version of a search. Using recursion will not require much additional space for recursive calls. Coding binary search recursively is somewhat easier.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents