Reference no: EM131864526
Assignment
1. The date June !0, 1960, is special because when it is written in the following format, the month times the day equals the year: 6/10/60. Design a program that asks the user to enter a month (in numeric form), a day, and a two-digit year. The program should then determine whether the month times the day equals the year. If so, it should display a message saying the date is magic. Otherwise, it should display a message saying the date is not magic.
2. Serendipity Booksellers has a book club that awards points to its customers based on the number of books purchased each month. The points are awarded as follows:
- If a customer purchases 0 books, he or she earns 0 points
- If a customer purchases 2 books, he or she earns 5 points.
- If a customer purchases 4 books, he or she earns 15 points.
- If a customer purchases 6 books, he or she earns 30 points.
- If a customer purchases 8 or more books, he or she earns 60 points.
Write a program that asks the user to enter the number of books that he or she has purchased this month, then displays the number of points awarded.
3. A software company sells a package that retails for $99. Quantity discounts are given according to the following table:
Quantity Discount
10-19 10%
20-49 20%
50-99 30%
100- or more 40%
Write a program that asks the user to enter the number of packages purchased. The program should then display the amount of the discount (if any) and the total amount of the purchase after the discount.
4. Write a program that asks the user to enter a number of seconds and works as follows:
- There are 60 seconds in a minute. If the number of seconds entered by the user is greater than or equal to 60, the program should convert the number of seconds to minutes and seconds.
- There are 3600 seconds in an hour. If the number of seconds entered by the user is greater than or equal to 3600, the program should convert the number of seconds to hours, minutes, and seconds.
- There are 86400 seconds in a day. If the number of seconds entered by the user is greater than or equal to 86400, the program should convert the number of seconds to days, hours, minutes, and seconds.
What would be the prospective stock price after the issue
: What was the total amount of new money raised? What would be the prospective stock price after the issue?
|
Determine the power delivered by the motor
: If oil leaves the motor at 200 psi, determine the power delivered by the motor.
|
What affect does parenting style have on the child behavior
: Describe how marital relationships, a child's age, and a child's temperament all contribute to the manner in which a parent "parents" a child.
|
What is the amount of the cash flow to creditors
: Logitech has net income of $320,000. What is the cash flow to stockholders? What is the amount of the cash flow to creditors.
|
Write a program that enter the number of packages purchased
: Write a program that asks the user to enter the number of packages purchased. The program should then display the amount of the discount.
|
Find the overall efficiency of the motor
: If the actual flow rate consumed by the motor is 75 gpm and the actual torque delivered by the motor is 1300 in.-Ib, find the overall efficiency of the motor.
|
Describe the four phases of a project
: Describe the four phases of a project in your own words and outline activities in each phase. Pick a project that would have a score of 1 on the DCPI.
|
What is the significance of stephens dying vision of jesus
: Cornelius is described in Acts 10 as devout, fearing God, and prayerful. Indeed, God took note of his good works and heard his prayers.
|
Find the equation of the best-fitting straight line
: In studying the "ozone-deficit" problem (Science, September 23, 1994, page 1835), one experiment measured laser-induced fluorescence
|