Skip to content

peterthompson/roman-numeral-calculator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Roman Numeral Calculator

Start by writing a Roman Numeral converter and from that Roman Numerals. Then write a Roman Numeral Calculator that takes a string i.e. “XXIV + XI” and returns the result which would be “XXXV”. Ideally it should perform all BODMAS calculation so:

  • Brackets: ()
  • Order (power): ^
  • Division: /
  • Multiplication: *
  • Addition: +
  • Subtraction: -

Assumptions

  • Cannot represent values greater than or equal to 4000 in Roman Numerals using only characters I, V, X, L, C and M.
  • Cannot represent fractions in Roman Numerals.
  • Cannot represent zero in Roman Numerals.

Scripts

Install dependencies

npm install

Run tests

npm test

Run program

npm start

About

A CLI Roman Numerals calculator.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published