Download presentation

Presentation is loading. Please wait.

1
In Class Exercises

2
Chapter 3, problem 25 Develop an application to compute the total cost of an order for MyJava Coffee Outlet including the boxes used to ship it. Coffee is sold in 2-lb bags which cost $5.50 each. SizeHoldsCost Large20$1.80 Medium10$1.00 Small5$0.60

3
Output Format Number of Bags ordered: 52 Cost of Coffee: $286.00 Boxes Used: 2 Large - $3.60 1 Medium - $1.00 1 Small - $0.60 Your total cost is: $291.20

4
Development Process Any questions about the specification? What classes do we need to use? Which do we need to write? How should we break down the development?

5
Adding Arrival date Use today's date as the date of order Expected arrival date is two weeks from date of order. Date of Order: September 13, 2005 Expected Arrival: September 13, 2005

6
Prime Numbers A prime number is a number greater than 1 which is divisible only by 1 and itself. Write a method that returns true if its parameter is a prime number Write code to generate a list of all the primes between 1 and some number.

7
Fibonacci Numbers The Fibonacci sequence is defined by f(1) = f(2) = 1 f(n) = f(n-1) + f(n-2) Write code to calculate the first N Fibonacci numbers

Similar presentations

© 2023 SlidePlayer.com Inc.

All rights reserved.

To make this website work, we log user data and share it with processors. To use this website, you must agree to our Privacy Policy, including cookie policy.

Ads by Google