13SearchingAlgorithms

13SearchingAlgorithms - CSE 114 Computer Science I...

Info iconThis preview shows pages 1–7. Sign up to view the full content.

View Full Document Right Arrow Icon
Sleeping Bear Dunes, Michigan CSE 114 – Computer Science I Searching Algorithms
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Midterm Exam 2 Next Thursday, 4/15 in this room during normal class time, 12:50-2:10
Background image of page 2
Midterm Exam 2 Material OOP, Inheritance, Polymorphism, Static vs. Non- Static Lecture 9 (Objects) – Lecture 18 (Statics) Labs 9 – 17 Sample Exam Posted to Schedule page
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Searching and Sorting Very common data structure operations Many different algorithms for each Each algorithms have their own tradeoffs Simplicity vs. Efficiency Today: Sequential Search vs. Binary Search Next Time:
Background image of page 4
What is searching used for? Finding a particular piece of data in a data structure Ex: an array of students find the student who is named Joe Shmo
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Searching - The Sequential Search Algorithm Target - data we are searching for Return the index of the target element in the array, if it’s not found, return -1 Algorithm: 1. Examine each element of an array one at a time in
Background image of page 6
Image of page 7
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 04/13/2010 for the course CSE 114 taught by Professor Tashbook during the Spring '08 term at SUNY Stony Brook.

Page1 / 12

13SearchingAlgorithms - CSE 114 Computer Science I...

This preview shows document pages 1 - 7. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online