Problem 1

If a, b, c, d, e, and f are integers in between 1 to 50, write a program that counts all the combinations with the same sum (e.g. given sum = 150 - prompt the user to enter the desired sum) of all the possible six-number arrangement in a row where

a ≠ b ≠ c ≠ d ≠ e ≠ f and a < b < c < d < e < f.

Example: a b c d e f

6 17 21 26 33 47 (6+17+21+26+33+47=150)

The program will construct the following table and will indicate which of the six-number combination has the desired sum. It would be useful to use counters to count the amount of six-number arrangement and the amount of combinations that satisfy the desired sum.

1 2 3 4 5 6
1 2 3 4 5 7

1 2 3 4 5 50
1 2 3 4 6 7
1 2 3 4 6 8

1 2 3 4 6 50
1 2 3 4 7 8

1 2 3 4 7 50

Problem 2

A parking garage charges a $2.00 minimum fee to park for up to three hours. The garage charges an additional $0.50 per hour for each hour or part thereof in excess of three hours. The maximum charge for any given 24-hour period is $10.00. Assume that no car parks for longer than 24 hours at a time. Write an application that calculates and displays the parking charges for each customer who parked in the garage yesterday. You should enter the hours parked for each customer. The program should display the charge for the current customer and should calculate and display the running total of yesterday’s receipts. The program should use the method calculateCharges to determine the charge for each customer.

Problem 3

Computers are playing an increasing role in education. Write a program that will help an elementary school student learn multiplication. Use a Random object to produce two positive one-digit integers. The program should then prompt the user with a question, such as

How much is 6 times 7?

The student then inputs the answer. Next, the program checks the student’s answer. If it is correct, display the message "Very good!" and ask another multiplication question. If the answer is wrong, display the message "No. Please try again." and let the student try the same question repeatedly until the student finally gets it right. A separate method should be used to generate each new question. This method should be called once when the application begins execution and each time the user answers the question correctly.

Problem 4

(Total Sales) Use a two-dimensional array to solve the following problem: A company has four salespeople (1 to 4) who sell five different products (1 to 5). Once a day, each salesperson passes in a slip for each type of product sold. Each slip contains the following:

  • The salesperson number
  • The product number
  • The total dollar value of that product sold that day

Thus, each salesperson passes in between 0 and 5 sales slips per day. Assume that the information from all the slips for last month is available. Write an application that will read all this information for last month’s sales and summarize the total sales by salesperson and by product. All totals should be stored in the two-dimensional array sales. After processing all the information for last month, display the results in tabular format, with each column representing a particular salesperson and each row representing a particular product. Cross-total each row to get the total sales of each product for last month. Cross-total each column to get the total sales by salesperson for last month. Your tabular output should include these cross-totals to the right of the totaled rows and to the bottom of the totaled columns.


Typical report length: 15 pages excluding, Abstract, Table of contents, References and Appendices.

The project report should be neat, readable, and self-contained. Also, it should be written with the readers in mind. Any class member should be able to understand your report, and benefit from the results you obtain. Therefore, you should include adequate references and/or background materials and you should use tables, diagrams, graphs, figures, and portions of printouts to enhance readers' comprehension of your project.

The following format is suggested. You don't have to follow it exactly. Some sections may not be needed, or additional sections may be necessary. In all cases, please type and paginate your report!

  • Abstract. Gives succinct information on the purpose, methods, results and conclusions reported. It comes first in your report, but you write it last.
  • Table of contents
  • Introduction. Include background material and discuss the scope and limitations of your project.
  • Discussion: the body of your report. This includes the methodology used. Be sure to fully describe any figures, tables or diagrams you include.
  • Results.
  • Conclusions.
  • Recommendations, especially for future work and unsolved problems.
  • References (must always be included), annotated if possible.
  • Appendices, including supporting material as needed.
Academic Honesty!
It is not our intention to break the school's academic policy. Projects posted are only used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly fill out the form. Please provide a valid email address and we'll get back to you in less than 24 hours. We will be sending an invoice through PayPal upon confirmation. We are a non profit organization however we need an amount to keep this organization running, and to be able to complete our research and development.