People who wish to send flowers to their near and dear ones, contact 'Fragrance Florist'. Ms. Sharma works as a programmer in "Fragrance Florist" where she has designed a software to compute charges to be paid by the customer. A screenshot of the same is shown below:
(i) A customer orders for one type of flowers out of Red Rose/OrchidAellow Rose.
(ii) A "Special Customer" gets a 50.00 discount on Amount.
(iii) Name, Phone Number Flower ordered, whether customer is a Special customer, Number of Stems is input by the user.
(iv) Amount, Discount (if any), Amount to pay are calculated and displayed by the program.
Amount is calculated using the following criterion :
Flower |
Price per Stem (in Rs) |
Red Rose |
15 per stem |
Orchid |
60 per stem |
Yellow Rose |
20 per stem |
(i) Amount is obtained by multiplying per Stem charges with number of stems bought.
(ii) If 'Special Customer' checkbox is selected, discount of Rs 50.00 is given on Amount.
Amount to Pay = Amount - Discount
Help Ms. Sharma by writing the code to do the following:
(i) After selecting appropriate Radio Button and checkbox (if Spl Customer), when 'Calculate' button is clicked, AMOUNT, DISCOUNT (IF ANY) and AMOUNT TO pay should be calculated and displayed in the respective text fields.
(ii) When 'CLEAR button is clicked, all text fields, Radio buttons and checkbox should be cleared.
(iii) When 'CLOSE' button is clicked, the application should close.