Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Life has been good to you so far. Now you have a job, and, you're thinking, life is even better now that you have a

image text in transcribedLife has been good to you so far. Now you have a job, and, you're thinking, life is even better now that you have a paycheck! However, your job has been trying, and a little bit boring. So, you'd like to take up some time developing an algorithm to make the job even easier than it already is. Here's you job: You are the Measure Minister. People in your town, being too stupid to use a yardstick , bring to you all their stuff to measure. Everything is measured in exact inches. (The foregoing fact makes this problem simple, albeit not realistic. Thus, for this problem, you can assume no one will ever bring you anything measuring 3.5 inches, or 78.23 inches, or 9.01 inches, or ...) Your only tool-o-measurement is a piece of string exactly 8 inches long. Write an algorithm that you (or your replacement) may use to measure in the most efficient way all the stuff that the townspeople might bring to you to measure. Remember, they can bring you little things or big things...or even really big things! Remember, your measures will always be to the nearest inch, and the string you use is exactly 8 inches long. yardtick ninja.

yardstick ninja 2. Life has been good to you so far. Now you have a job, and, you're thinking, life is even better now that you have a paycheck! However, your job has been trying, and a little bit boring. So, you'd like to take up some time developing an algorithm to make the job even easier than it already is. Here's you job: You are the Measure Minister. People in your town, being too stupid to use a yardstick, bring to you all their stuff to measure. Everything is measured in exact inches. (The foregoing fact makes this problem simple, albeit not realistic. Thus, for this problem, you can assume no one will ever bring you anything measuring 3.5 inches, or 78.23 inches, or 9.01 inches, or ...) Your only tool-o-measurement is a piece of string exactly 8 inches long. Write an algorithm that you (or your replacement) may use to measure in the most efficient way all the stuff that the townspeople might bring to you to measure. Remember, they can bring you little things or big things.....or even really big things! Remember, your measures will always be to the nearest inch, and the string you use is exactly 8 inches long. Toothpaste For Dinner.com 3. Here's the deal: You have to get to class at noon. You wake up in the morning according to your alarm clock. Class is 12 miles away from your bedroom. You want to get there in the most economical way and on time. Your modes of transport are: walking, (max speed 3 mph and not limited to road surfaces) o stupid motor bike, (max speed 10 mph and 70 mpg, but limited to road surfaces) Abrams M1 tank, (max speed 65 mph, not limited to road surfaces!) Cooooool! But, only gets 0.4 mpg. Other considerations include: 1. traffic conditions (you have a traffic radio). 2. the weather (you also have a weather radio). You will not want to walk or drive the moped in bad weather. Bad traffic can halt a moped. Nothing can halt an M1 tank. Write an algorithm that you can use to decide how you will get to class on time with as little monetary expenditure as possible given the above conditions

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions