Question: Question 1 : You're developing a subscription management system. Write a function named calculateSubscriptionCost that calculates the total cost of a subscription plan based on

Question 1: You're developing a subscription management system. Write a function named
calculateSubscriptionCost that calculates the total cost of a subscription plan based on the
provided parameters.
The function should take in three arguments
1.basePrice (number): The base price of the subscription plan.
user Type (string): Represents the type of user - cither "regular" or "premium".
months (number): The number of months for which the subscription is being purchased.
For "regular" users, there's no discount.
For "premium" users, apply a 20% discount on the base price. Means multiply by 0.80
Calculate the total cost of the subscription for the given number of months after applying the discount.
In HTML Page create a division with class named form container having title as heeding 2 Subscription
cost system containing the three arguments discussed in the question
Some Designs are applied to this page as follow:
The form-container should have a maximum width of 420px, centered using margin 0 auto, using
and bordered with a 1 px solid color of #cec. It should also have a border radius of 5px, along with
20px of padding.
All heading 2 must be aligned center with margin bottom 20px and blue color
All labels in the form must be displayed block with margin bottom 5px
All text input and select Should be set to a width of 94%. They should have 5 px padding, an 8 px
bottom margin, a border radius of 3 px, and a border of 1 px solid color Hece.
The input type button needs to have a background color of H4CAF50, white font color, and padding
set to 8px by 12px. It should have no border, a border-radius of 3px, a pointer cursor, and a width
of 94%
Subscription Cost System
Base Price
]
User Type
Number of Months
No Discount the cost is: 600
 Question 1: You're developing a subscription management system. Write a function

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!