Skip to content

ashishp91/simple_calculator

Repository files navigation

Simple Calculator app

How to setup ?

  • Install ruby version 3.2.4
  • Run bundle install
  • Run rspec

File structure

Under app/services, these files are present:

  • ExtractDelimiterService - This is used to parse and extract any custom delimiter that is present at the start of the input string.
  • InputParserService - This is used to parse the input string and fetch the numbers from it.
  • SimpleCalculatorService - This is the main file which uses previous services to parse the string and calculate the sum.

Test cases are written in rspec and present under spec/ folder.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages