Skip to content

ProblemShooter/Advance_calculator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

5 Commits
ย 
ย 
ย 
ย 

Repository files navigation

Advance_calculator

An advanced calculator built using Python and Tkinter. This calculator supports basic arithmetic operations, scientific functions, memory operations, and theme customization. It also includes a history panel to track previous calculations.

Calculator Screenshot image


Features

  • Basic Arithmetic: Addition, subtraction, multiplication, and division.
  • Scientific Functions: Square root (โˆš), exponents (^), logarithms (log, ln), and trigonometric functions (sin, cos, tan).
  • Memory Operations: M+, M-, MR, MC for storing and recalling values.
  • History Panel: Displays previous calculations for easy reference.
  • Theme Customization: Switch between light and dark themes.
  • Keyboard Support: Use the keyboard for input (numbers, operators, and special keys like Enter, Backspace, Esc).
  • Error Handling: Displays user-friendly error messages for invalid expressions.
  • Closing Braces: Supports parentheses () for complex expressions.

Installation

  1. Prerequisites:

    • Python 3.x installed on your system.
    • Tkinter (usually comes pre-installed with Python).
  2. Clone the Repository:

    git clone https://github.com/your-username/Advanced-calculator.git
    cd Advanced-calculator
  3. Run the Calculator:

    python Advanced_calculator.py

Usage

Using the Calculator

  • Buttons:

    • Click on the buttons to input numbers, operators, and functions.
    • Use the C button to clear the input.
    • Use the = button to evaluate the expression.
    • Use the Theme button to switch between light and dark themes.
  • Keyboard:

    • Use the keyboard to input numbers, operators, and parentheses.
    • Press Enter to evaluate the expression.
    • Press Backspace to delete the last character.
    • Press Esc to clear the input.

Memory Operations

  • M+: Add the current value to memory.
  • M-: Subtract the current value from memory.
  • MR: Recall the value stored in memory.
  • MC: Clear the memory.

History Panel

  • The history panel displays all previous calculations.
  • Click on a calculation to reuse it.

Code Structure

  • Advanced_calculator.py:

    • Main script containing the calculator logic.
    • Handles button clicks, keyboard input, and theme switching.
  • Dependencies:

    • tkinter: For the GUI.
    • math: For scientific functions.

Screenshots

Dark Theme

Dark Theme

Light Theme

Light Theme

Contributing

Contributions are welcome! If you'd like to add new features or improve the calculator, follow these steps:

  1. Fork the repository.
  2. Create a new branch (git checkout -b feature/your-feature).
  3. Commit your changes (git commit -m 'Add some feature').
  4. Push to the branch (git push origin feature/your-feature).
  5. Open a pull request.

License

This project is licensed under the MIT License. See the LICENSE file for details.


Acknowledgments

  • Built with โค๏ธ using Python and Tkinter.
  • Inspired by modern calculator apps.

Contact

For questions or feedback, feel free to reach out:


Enjoy using the Advanced Calculator! ๐Ÿ˜Š


Let me know if you need further assistance! ๐Ÿ˜Š

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages