GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - BaseMax/PythonExpressionInterpreter: Simple Math Interpreter in Python

BranchesTags
Open more actions menu

Latest commit

 

History

29 Commits
29 Commits

Folders and files

NameName
Last commit message
Last commit date
LICENSE
LICENSE
 
 
README.md
README.md
 
 
interpreter.py
interpreter.py
 
 
interpreter_test.py
interpreter_test.py
 
 
lexer.py
lexer.py
 
 
lexer_test.py
lexer_test.py
 
 
main.py
main.py
 
 
nodes.py
nodes.py
 
 
parser.py
parser.py
 
 
parser_.py
parser_.py
 
 
parser_test.py
parser_test.py
 
 
tokens.py
tokens.py
 
 
values.py
values.py
 
 

Repository files navigation

Python Expression Interpreter

Simple Math Interpreter in Python

Using

python main.py

Example

calc > 5
5.0
calc > -110
-110.0
calc > --110
110.0
calc > ---110
-110.0
calc > 5*4+5
25.0
calc > 5/2+4*4+(5/4-2)+1/1
18.75

Unit Testing

python -m unittest lexer_test
python -m unittest parser_test
python -m unittest interpreter_test 

References

  • https://www.youtube.com/watch?v=88lmIMHhYNs
  • https://www.youtube.com/watch?v=TwKWUj033vY
  • https://www.youtube.com/watch?v=45epnUwFALo
  • https://www.youtube.com/watch?v=tczjDCbykyM

About

Simple Math Interpreter in Python

github.com/One-Language/One

Topics

interpreterlexermath-expression-evaluatormath-expression-parsermath-expression-solvermath-expressionsmathematical-expressionsparserpython

Resources

Readme
License
Activity

Stars

1 star

Watchers

1 watching

Forks

0 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.