Skip to content

HoangNguyen679/snow

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Overview

Implement equation evaluate by stack with fraction support. Input equation by array of elements. Element can be number, fraction, operator and parentheses.

Purpose

Handle equation when already know all terms and operators.

Demo

❯ yarn dev

Start!!!
Compute: 1 + 2 * 3 = 3
Compute: 1 + 2 * 3 = 7
Compute: (1 + 2) * 3 = 9
Compute: 1 + (1/2) = 1.5
Compute: 1 + (1/3) = 1.3333333333333333
Compute: 1 + (1/3) + (1/2)= 1.8333333333333333
Finish!!!
Start Fraction!!!
Compute: 1 + 2 * 3 = 3/1
Compute: 1 + 2 * 3 = 7/1
Compute: (1 + 2) * 3 = 9/1
Compute: 1 + (1/2) = 3/2
Compute: 1 + (1/3) = 4/3
Compute: 1 + (1/3) + (1/2)= 11/6
Finish Fraction!!!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published