Skip to content

VikaTheDuck/COMP354

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Algo-lator

Final Project Submission for Introduction to Software Engineering (COMP 354) Fall 2021

Algo-lator is a calculator built to help teach young children who can read and write how to develop simple algorithms. Using Algo-lator's specially designed syntax even young children can begin to construct their own algorithms and execute them in real time. Algo-lator displays the execution result along with comprehensive error messages should an error occur to help the user understand and fix their errors. Start writing your own algorithms with Algo-lator now by simply following the setup instructions below!

Usage

Running the full application with GUI

> python TextEditor.py 

Running tests

> python Parser.py
> python Expression.py

Try some sample inputs:

  • 10 plus 5
  • 10 minus 5
  • 5 plus 2 for 5 times
  • let x equal to 5
  • if x is greater than 2 then x else 0
  • x plus 5
  • 10 plus 2 minus if 5 is greater than 2 then 5 plus 2 else 0

Modifying tests

To modify or add any test cases simply add a dictionary entry in the form:
{'input' : '[input string]', 'expected' : [expected result]}
into the respective test array within the .py file

*Note: Assignment and Exception handling tests must contain only base Assignment() and _Exception() objects respectively
ie. 'expected' : Assignment() and 'expected' : _Exception()

Syntax Table

Operation Input Parsed Output
Addition 5 plus 7 5 + 7
Subtraction 5 minus 7 5 - 7
Assignment let x equal to 5 x = 5
Conditional if 5 is greater than 2 then 5 + 7
Loops Add 1 to x for 5 times (1 + x) for 5 times

Troubleshooting

# replace 'python' with one of the following while running a file
1) > python3 <filename>
2) > py <filename>

Missing package tk or tkinter

Try one of the following solutions

1) > pip install PySimpleGUI
2) > pip install python-tk
3) package installation
# Linux
> sudo apt-get install python3-tk
# Mac
> brew install tcl-tk
# Windows
# Ensure tcl/tk option is selected during python installation

Team Members

Efe Harmankaya
Ian Mullett
Donovan Upsdell
Sarah Joyal
Victoria Solodovnikova
Ibrahim Tawakol

About

COMP 354 Fall 2021

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 5

Languages