Exam1Review-15121

Exam1Review-15121 - 15121 Exam 1 Review: Spring 2011 Your...

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

View Full Document Right Arrow Icon
15121 Exam 1 Review: Spring 2011 Your lifelong friend Farmer John is in trouble! Farmer John has owned his farm for years, thriving in Amish country. Last year, he won both of Pennsylvania‟s most prestigious cattle farm awards, the Milk Milk and Moo Moo awards for the best quality and most milk produced produced on any farm in the country. He is reputedly one of the kindliest and most knowledgeable people around, and has made some sizeable donations to charity. However, his evil twin brother , a.k.a. “Fe el- Good Jones” Jones is trying to steal away this years awards. Feel-Good Jones recently renounced the Amish life. After his twin brother Farmer John let him win in a game of ping pong when he was having a bad day, he decided he did not want to be pitied any longer. Feel-Good Jones betrayed his family, and got a computer and began to implement some technology on his farm. Farmer John then approached you for help. He had an idea: perhaps HE couldn‟t touch technology but maybe you can! Farmer John, though, is actually an expert computer scientist . He wants to make sure you are proficient with your big O notation before he takes you on as a consultant , so he‟ s given you a short quiz: Big O What do these running times look like in Big O notation? O(__ ) Constant O(___ ) Linear O(___ )Logarithmic O(____ ) Quadratic O(____ ) Exponential Put these run times in order of increasing amount of time: ______ < ______ <______ < ______ << ______ What would be the running time if a logarithmic operation was performed a linear number of times? ______________ What would be the running time if a quadratic operation was performed a linear number of times? ______________
Background image of page 1

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

View Full DocumentRight Arrow Icon
What would be the running time if a linear operation was performed a logarithmic number of times and constant operation was performed a quadratic number of times? ______________ Determine the running time of these functions.
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 8

Exam1Review-15121 - 15121 Exam 1 Review: Spring 2011 Your...

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

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