View Single Post
Old Apr 8th, 2008, 1:58 PM   #4
reddyfire
Newbie
 
Join Date: Apr 2008
Posts: 2
Rep Power: 0 reddyfire is on a distinguished road
Re: Complex Number Calculator

Quote:
Originally Posted by OpenLoop View Post
java Syntax (Toggle Plain Text)
  1. StringTokenizer t = new StringTokenizer(inp, "+- //t/n/ri");
I think this is your problem. If I understand it correctly, this will return the numbers delimited by + or - or tab... So it will ignore the delimiter, and return the values between them causing you to lose the negative sign.
Yes that fixed my problem thank you very much.
reddyfire is offline   Reply With Quote