CodeX
Published in

CodeX

Easy Java Swing exercise: Tip calculator

As of June 1, 2021, restaurants in Michigan are allowed to ramp up to 50% capacity. They were restricted to 25% capacity because of health department restrictions. If you go eat at a restaurant, tip your waiter well. Photo by Bimo Luki on Unsplash

Single-purpose calculators are frequently used as exercises for Java beginners. The instructor tasks the students with writing a command line program that calculates the area of a room in square feet, or it calculates body mass index (BMI), or it converts an amount of money in one currency to another, etc.

To do the same thing with a graphical user interface (GUI), such as with Java Swing…

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store