Basic calculator

not passing all test cases
https://hack.codingblocks.com/app/contests/1483/461/problem