1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Sholpan [36]
3 years ago
6

An internet service provider has three different subscription package for its customers:Package A: For $9.95 per month 10 hours

of access are provided. Additional hours are $2.00 per hour.Package B: For $13.95 per month 20 hours of access are provided. Additional hours are $1.00 per hour.Package C: For $19.95 per month unlimited access is provided.Write a program that calculates acustomer's monthly bill. It should ask the user to enter the letter of the package the customer has purchased (A,B,C) and the number of hours that were used.It should then display the total charges. In addition calculate and display the amount of money Package A customers would save if they purchases Package B or C, and the amount of money package B customers would save if they purchased Package C. If there would be no savings, no message should be printed.
Business
1 answer:
dimaraw [331]3 years ago
7 0

Answer:

# The user is prompt for input to enter type of package

# the received input is capitalize

selected_package = str(input("Enter the package that you purchased.")).capitalize()

# The user is prompt for input to enter number of hours

hours_used = int(input("Enter the hours that you use for the purchased package."))

# Basic price for package a

base_price_package_a = 9.95

# Basic price for package b

base_price_package_b = 13.95

# Basic price for package c

base_price_package_c = 19.95

# additional price for package a

additional_price_a = 2

# additional price for package b

additional_price_b = 1

# total charge for the entire internet consumption

total_charges = 0

# if user entered A

if(selected_package == str('A')):

   # additionail hour is calculated

   extra_hour = hours_used - 10

   # total_charge is calculated for package a

   total_charges = base_price_package_a + (extra_hour * additional_price_a)

   # total charge for package a is displayed

   print("Your total charges using package A is: $",total_charges)

# if user entered B    

elif(selected_package == str('B')):

   # additionail hour is calculated

   extra_hour = hours_used - 20

   # total_charge is calculated for package b

   total_charges = base_price_package_b + (extra_hour * additional_price_b)

   # total charge for package b is displayed

   print("Your total charges using package B is: $",total_charges)

# if user entered C    

elif(selected_package == str('C')):

   print("You bought package C")

# amount to be saved

amount_saved = 0

# if user bought package A and total charge exceed 13.95

if (selected_package == str('A') and total_charges > base_price_package_b):

   # amount saved if package a is bought is calculated relative to package b

   amount_saved = total_charges - base_price_package_b

   # amout saved is printed

   print("You would have saved $",amount_saved, " if you bought package B")

   # amount saved if package a is bought is calculated relative to package c

   amount_saved = total_charges - base_price_package_c

   # amout saved is printed

   print("You would have saved $",amount_saved, " if you bought package C")

# if user bought package B and total charge exceed 19.95    

elif(selected_package == str('B') and total_charges > base_price_package_c):

   # amount saved if package b is bought is calculated relative to package c

   amount_saved = total_charges - base_price_package_c

   # amout saved is printed

   print("You would have saved $",amount_saved, " if you bought package C")

Explanation:

The code is written in python and well commented.

You might be interested in
Which is the difference between static storage systems and dynamic storage systems
arlik [135]

Answer:

In a static storage area each product is assigned a specific area, whereas in dynamic storage, product locations and fluid and as such are subject to change.

3 0
3 years ago
Maria Alverez has received a paycheck for $250, which she wishes to cash at her bank. She will need to use a blank endorsement o
nlexa [21]

She would need an Address an   Social Security number (or ITIN)  with a

Valid ID

8 0
3 years ago
2.1: A debit is A : a decrease to an account. B : an entry on the left side of an account. C : an entry on the right side of an
Luba_88 [7]

Answer:

B : an entry on the left side of an account.

Explanation:

There are two terms i.e debit and credit.  

The accounts that reported as an expense, losses, assets are recorded in the left-hand side of an account as it contains the debit balance.

While the account reported as a revenue, gains, liabilities & stockholder equity are recorded in the right-hand side of an account as it contains the credit balance.

7 0
3 years ago
You are considering acquiring a common share of Sahali Shopping Center Corporation that you would like to hold for 1 year. You e
kodGreya [7K]

Answer:

$42.60

Explanation:

Current value = Future dividends and value*Present value of discounting factor(rate%,time period)

Current value =  $1.85 / (1+10%) + $45 / (1+10%)

Current value =  $1.85/1.1 + 45/1.1

Current value = $ 1.68181 + $40.91

Current value = $42.5918

Current value = $42.60

3 0
3 years ago
Investing in stocks is like gambling when:
bearhunter [10]
If so maybe see hope help
6 0
2 years ago
Other questions:
  • A CPA can accept a gift from a client as long as:
    10·1 answer
  • What document is a roadmap to help the facility executives reach the facility's goals?
    14·1 answer
  • Suppose that demand for a product is Q = 1200 − 4P and supply is Q = −240 + 2P. Furthermore, suppose that the marginal external
    9·1 answer
  • A Statement of Financial Position is a formal statement presenting the three accounting elements which are?
    12·1 answer
  • By selling shares of ownership in their company, California Scientific acquires the funds needed to finance their research and d
    15·1 answer
  • Albo Corporation and Black Corporation are identical in every way except their capital structures. Albo Corporation, an all-equi
    6·1 answer
  • The article entitled​ "My Drug​ Probem" best reflects the economic idea that A. ​Pharmac, like private drug​ companies, attempt
    6·1 answer
  • Jenna has been working at Firenzi Entertainment Group for the past 3 years as a location scout. One of Jenna's chief responsibil
    6·1 answer
  • At present, the gap between those employees who say they want unions and those that have union representation in the private sec
    15·1 answer
  • Suppose the digby company begins to compete through good designs, high awareness and easy accessibility for their existing produ
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!