Write a simple Java Swing/AWT-based application for a Counter. The UI contains a Label ("Counter"), a non-editable TextField, and 2 Buttons ("Count" and "Reset"). The TextField will show the value of the counter. Clicking the "Count" Button will increase the value of the counter and display the value in the TextField. Clicking the "Reset" button will reset the TextField value back to 0. [4] Counter text field non-editable.
Count
Reset
Make the TextField of Question editable and add the following:
a. If the user enters a number in the TextField, clicking the Button will increase the number by and show the value. [1] Counter text field editable.
Create a calculator application that can perform addition, subtraction, multiplication, and division operations. Your application will consist of three TextFields side by side. In the first TextField, the user will input a number. In the second TextField, the user will input the operation to be performed (+, -, *, or /). In the third TextField, the user will input the second number. The application will contain a Button with the text "Result". When the button is clicked, the result of the operation will be displayed in another TextField. In case of any exception, this last TextField will show "Invalid". [10] Label non-editable.