Skip to content

Instantly share code, notes, and snippets.

@firesofmay
Created December 22, 2014 13:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save firesofmay/7b996877bed1fa042054 to your computer and use it in GitHub Desktop.
Save firesofmay/7b996877bed1fa042054 to your computer and use it in GitHub Desktop.
Inputs
| TestCase | Input | Output | Expected |
|----------+-----------------+---------------+----------|
| 01 | "" | "" | Error |
| 02 | "()" | "" | Error |
| 03 | " 1 + 2 " | Invalid Input | 3.0 |
| 04 | "11" | 11 | 11.0 |
| 05 | "2-4+6" | 22.0 | 4.0 |
| 06 | "2-4+6-1-1-0+8" | 21.0-18.0 | 10.0 |
| 07 | "1-1+2-2+4-4+6" | 11.02.02.0 | 6.0 |
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment