Include a brief documentation file explaining the app
Include a brief documentation file explaining the app
1. Basic Arithmetic Operations: The app supports addition, subtraction, multiplication, and division
operations.
2. Parentheses Support: The app allows the use of parentheses to group and prioritize calculations.
3. Clearing and Backspace: The "AC" button clears both the input and output fields.
4. Decimal Point: The app includes a decimal point button to input decimal numbers.
5. Error Handling: The app handles errors in the mathematical expressions and displays "Err" or
"Error" when an invalid expression is entered.
6. Real-Time Calculation: The app calculates the result in real-time as the user inputs the
expression.
7. Dynamic Input and Output Fields: The app uses TextView to display the input expression and the
corresponding result.
8. Responsive UI: The UI components are designed using Material Design, providing a clean and
user-friendly interface.
Overall, the design focuses on simplicity and ease of use, providing a familiar and intuitive calculator
experience to the users.
1. User Interface (UI): The app follows a simple and user-friendly design, resembling a basic
calculator layout.
2. Screen Layout: The app uses a RelativeLayout as the root layout, which allows for flexible
positioning of elements on the screen.
3. Output Display: The app has two TextView elements: Output and Output2. These TextViews
display the calculation input and output.
4. Button Styling: The numeric and operator buttons are styled using MaterialButton from the
Material Design library. Buttons have a consistent size, rounded corners
(app:cornerRadius="10dp"), and different background colors to differentiate numeric buttons
from operator buttons.
5. Button Placement: The buttons are organized in a grid-like layout using nested LinearLayout
elements. Numeric buttons (0-9) are arranged in four rows, and the operator buttons are placed
in separate rows at the bottom.
6. Responsive Text Size: The text size for the output TextViews and buttons is set appropriately to
ensure visibility and adjustability on different screen sizes.
7. Color Scheme: The color scheme of the app is based on primary colors like blue (#303F9F) for
the main layout background and red (#E30F0F) for operator buttons. Other colors like green
(#00796B) and orange (#F57C00) are used for special buttons.
8. Functionality: The app implements basic calculator functionality, including addition, subtraction,
multiplication, division, parentheses support, decimal point input, and an "equals" button to
display the result.
Challenges:
The major challenge I came across in making this calculator app was importing Mozilla Rhino JavaScript
engine.