COMP 250 Lecture Notes - Lecture 16: Pseudocode

15 views9 pages

Document Summary

October 17 big o, big omega, big theta. We are trying to understand how long it takes for an algorithm to run. There are so many things happening when you write out pseudocode. We want to concentrate on some things and ignore other things. We are generally interested in how the time it takes goes with the size of the input (the number of digits in a number we"re looking at, the number of elements in a list, etc). We don"t want to pay attention to random constants. Not sure how long it takes to do each thing, but we know it depends on n (the stuff on the loop), whereas the stuff in the beginning and end happen only once. The stuff inside the loop takes a constant amount of time, and the stuff outside the loop takes a constant amount of time.

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