Finding a value: scan, halve, or sort firstLesson 1 of 8Free preview
Scanning: line by line through the manifest
Mr Rafiq needs 10 looks to find #146, and 12 to say a parcel is missing. Array or list, a scan costs O(n).
Finding a value: scan, halve, or sort firstLesson 1 of 8Free preview
Mr Rafiq needs 10 looks to find #146, and 12 to say a parcel is missing. Array or list, a scan costs O(n).