To create and add the customer record to the database

Assignment Help Database Management System
Reference no: EM132080149

You need help using the Python to write this program (Python Question): Please see the question below:

During the tax season, every Friday, the J&J accounting firm provides assistance to people who prepare their own tax returns. Their charges are as follows:

If a person has low income (<= 25,000) and the consulting time is less than or equal to 30 minutes, there are no charges; otherwise, the service charges are 40% of the regular hourly rate for the time over 30 minutes.

For others, if the consulting time is less than or equal to 20 minutes, there are no service charges; otherwise, service charges are 70% of the regular hourly rate for the time over 20 minutes.

(For example suppose that a person has low income and spent 1 hour and 15 minutes, and the hourly rate is $70.00. Then the billing amount is 70.00 X 0.40 X (45 / 60) = 21.00).

Write a program that prompts the user to enter the customer first and last name, hourly rate, the total consulting time, and income. Once the customer information is entered, the program should generate and store a record for the customer. The customer record should include a 6-digit customer id (customer id will be generated by the program).

The customer id should be used as a key to retrieve the customer information (first and last name, income, hourly rate, consulting time, income, and billing amount).

Program should use a function, generateRecord, to create and add the customer record to the database (a dict that stores customers' information). generateRecord function takes first and last name, hourly rate, the total consulting time, and income as arguments. The program should calculate the billing amount and append/include it in the customer record.

Your program must contain a function, generateBillAmount that takes as input the hourly rate, the total consulting time, and the customer income.

The generateBillAmount should return the billing amount. The program should use a loop to process multiple customers. To exit the loop, the user should hit enter without entering customer information. Upon exiting the loop, the program should print each customer information. If the database does not contain data, the program should print the following: " No customer to print".

Reference no: EM132080149

Questions Cloud

Find a list of courses where the percentage of students : List of professors that work for departments with more than 20 faculty members and that offer more large sections than small and medium sections combined.
What is the income velocity of money in freedonia : The money supply is growing at 12% per year and real income, Y, is growing at 4% per year.
Price of a chinese-made car : Which does an increase in the price of a Chinese-made car that is popular among U.S. consumers show up in?
Write a program that transmits a series of characters : Write a program that transmits a series of characters (in C).The sequence will consist of "AlphaNumber", where Alpha is meant to be a letter.
To create and add the customer record to the database : Program should use a function, generateRecord, to create and add the customer record to the database (a dict that stores customers' information).
What would be the reasons for your selection : Which of the two methods would you select to use? What would be the reasons for your selection?
Compute the final percentage score for each student : Write an awk script called activity6.1-8.awk that compute the final percentage score for each student, as well as the class average
Watch the episode of simpsons bart gets an elephant : Watch the episode of The Simpsons "Bart Gets an Elephant". In the episode, the Simpsons find that their pet elephant
Write a method called totalhours that takes three integer : Write a method called "totalHours" that takes three integer arguments (number of weeks, number of days, number of hours) and returns the total integer hours.

Reviews

Write a Review

Database Management System Questions & Answers

  Suppose we have a relation employees ssn name department

suppose we have a relation employees ssn name department salary.nbspfor each of the following queries either write the

  What are the advantages of dbms

What are the advantages of DBMS? What are the advantages and disadvantages of RDBMS and ODBMS? What issues should be considered when choosing a database and a DBMS?

  Write a blog on any famous journalist

Write a blog on any famous journalist, or any other personality related to media

  Describe your experiences related to your setup of mysql

Describe your experiences related to your setup of MySQL. Include any difficulties or issues that you had encountered during the installation.

  Write a c program that reverses bytes of a given arbitrary

Write a C program that reverses bytes of a given arbitrary length file and outputs them to another specified file, which should overwritten if it already exist.

  What are the advantages and disadvantages of each method

What are the advantages and disadvantages of each method? Are there any inherit dangers with either method

  Explain fundamental concepts of database management systems

IT234- You are a presales consultant for an IT services company trying to close the sale for an upgrade of the systems of XYZ Corp. Explain the fundamental concepts of Database Management systems.

  How complicated are my data management tasks

To keep specific rows and columns from scrolling off the screen you first must position the cell pointer

  Create data dictionary that includes description of content

Create a data dictionary that includes the a description of the content for each field, The data type of each field, The format the data will be stored as in the field and The range of value for the field.

  Advantages of database approach over file-system approach

How and why did database management systems become the organizational data management standard? Describe some advantages of database approach over file-system approach.

  Draw the relational diagram

The table structure shown in Table contains many unsatisfactory components and characteristics. For example, there are several multivalued attributes.

  Describe the normal forms violated in the design

Describe the normal forms violated in the following design and fix them to the third normal form.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd