Joined
Last Seen
0 Reputation Points
Unknown Quality Score
No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
0 Endorsements
Ranked #107.65K
1 Posted Topic
The problem will be solved if you write the following: [COLOR="Green"]case PLUS: if(expr.substr(0,i) != "") return evaluateExpr(expr.substr(0,i))+evaluateExpr(expr.substr(i+1,expr.length()-i-1)); else return evaluateExpr(expr.substr(i+1,expr.length()-i-1)); case MINUS: if(expr.substr(0,i) != "") return evaluateExpr(expr.substr(0,i))-evaluateExpr(expr.substr(i+1,expr.length()-i-1)); else return -evaluateExpr(expr.substr(i+1,expr.length()-i-1)); //the number is negative[/COLOR]
The End.
Naira88