Tip Calculator Programs

December 06, 2019

To keep in practice with programming, I looked up programming samples and seen the Tip Calculator as a sample project that showed up on several programming practice lists. I did some feature creep on the idea to include more items. This way it wasn’t the same tip calculator that is seen everywhere and that would be created in most classes. Those features include: if more than one person is splitting the tip and then if they were all going to split the bill. I created the application in two different programming languages, Visual Basic, and the other as a Web Application using HTML, CSS, and JavaScript.

The app will take the amount of the bill, multiples that with the tip percentage to get the full amount of the tip. It will do two math equations: divide the tip by the number of people, then in another variable adds the total tip to the amount of the bill and divides that by the number of people. The totals of those two will then be rounded up to the nearest cent. It will then display the three totals: Bill Cost, Tip Amount, and Grand Total per person. If no people are added to the splitting of the bill, only tip amount and total will show. If there is no amount or no service selected, then an error message will be displayed.

You can download and play with the Visual Basic program here:
https://www.lynnamacher.com/programs/BillCalculator.exe.zip

Link to codepen for the web app version:
https://codepen.io/amacher13/pen/ZEzNJbo

 

Related Articles

Archive Project part 1

Archive Project part 1

The issue that came up was when I went back to an old CD archive to pull an old Business card I worked for somebody, they needed some updates. I noticed that the Mac wouldn’t read the disc or the next 2 I tried. In research found that the current Mac OS doesn’t...

read more
Python pull email addresses to CSV file

Python pull email addresses to CSV file

Another practicing Python project the original idea for this project came when I heard somebody talk about their email program got updated and all their contacts disappeared. First thought they would need to go through and add their contacts back. Then thought how...

read more
Random name picker

Random name picker

The idea of this Python project comes from who gets to go first or what order do a group of people go in. Think of kids getting ready to play a game and need to decide who goes first and what order they go in. They might do something like pull a card from a deck or...

read more

Pin It on Pinterest

Share This