Skip to content

boren-xue/Calculator

Repository files navigation

Calculator

A powerful calculator.

How to open

APK: app-debug.apk

Google Play Store: https://play.google.com/store/apps/details?id=com.bx.calculator

Logic

Expression Evaluating Algorithm:

Shunting-yard algorithm, which some modifications for pre-functions, post-functions, implied multiplication and negations.

Reverse Polish Notation

Abstract Syntax Tree

Code

Data types

  • CToken

    A token in a mathematical expression. It could be a number, operator, variable, etc.

  • CExpression

    An object representing a mathematical expression, an array of tokens.

  • CParams

    An object containing parameters for a calculation, including angle units and values for variables.

  • CResult

    An object respresenting the result of a calculation. It includes the original expression, calculation parameters and the calculated result. The result does not have to be correct after re-calculating the original expression if the calcuation algorithm has changed.

References

Screenshots

Screenshot 1 Screenshot 2 Screenshot 3 Screenshot 4 Screenshot 5

About

A calculator Android app.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages