Adding JavaScript StringCalc implementation