![]()
Using HTML we are giving desired structure, option for the input, and submit button. Total is basically amount multiplied by type of service divided by a number of persons. A per the inputs from the user, we are calculating the tip and then printing it using the console.log() function. To find out the tip we will take input from the user: Bill Amount (it is the amount of the total bill, we are taking this into amount variable), for the type of service we are using a drop-down menu having quality as the options in percentage (like good, bad, excellent, etc.), lastly, we are taking the number of persons as input (it will help to divide the tip equally among all the person). As per the three inputs it generates a tip for the serving person. In this project, a simple tip calculator is made which takes billing amount, type of service, and a number of persons as input. The tip is the money given as a gift for good service, to the person who serves you in a restaurant. #JAVASCRIPT CSS HTML CALCULATOR CODE HOW TO#
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |