It's not an eclipse error, it's a math error.
I input 99.99 one char at a time into that method, then print the stack.
It should print 99.99
Instead I get 9 0 9
Type: Posts; User: Herah
It's not an eclipse error, it's a math error.
I input 99.99 one char at a time into that method, then print the stack.
It should print 99.99
Instead I get 9 0 9
I am writing a method that takes in a string of characters, one character at a time. I am forming the combination of number, decimal point and exponent into a long and adding it to a stack. This has...
Okay, I don't really understand what you mean. Should I change the frame class into a panel, then add it to a new class called applet?
Hi everyone. This is my first time attempting to port a java application to an applet and I am pretty lost on what to do. I wrote it in full in eclipse and it runs fine as a jar but I'd like to be...
I am currenty working on a program involving queues for my data structures class.
The premise is very common among college assignments I'm told, but I am having trouble puzzling it out. Here are...
Well I just figured it out, sorry. How do I delete this thread?
Figured it out...
You are using string comparison to compare chars.
(s.equals('1')) should be (s.equals("1)) etc. Right now, it's false.
I guess you no longer need help, since you obscured the original post.
you need to add:
maxLength = longName.length();
place this after longName = name;
I am looking for some help with saving a file / loading it back up again. I am going to avoid the whole serialization thing, I hope, but simply writing a text file, and reading it back in. This is...
I am having trouble implementing a window on a game I have designed.
The game has a class, GUI, which includes the frame for the game itself, a menu, and multiple panels. When I choose "options"...
"Write the pseudocode for a tableDelete operation when the implementation uses hashing and separate chaining to resolve collisions."
I don't even understand what this says!
I am working on a program that creates several lists of random numbers, then runs sort algorithms on them and tracks the time it takes them to run. I've had no trouble building the lists, and running...
You are declaring your variables more than once, but I am not sure why you're doing so.
instead of declaring them inside of main, or inside of any other method, declare them in your class before...
Nothing is automatic. If it was "automatically entering a y", it was coming from somewhere. Setting it null in the middle of the while loop wouldn't matter, since it's then changed again right...
What is Answer = '\0' doing?
Since you need the game to run until something specific happens (you roll a 1 or a 6), how about using a while loop?
You can declare a variable to store the most recent dice roll, and base the while...
I am taking snippets from your code that are relavant.
String grade; //initialize variable in main method...but what are you initializing it to? It's null...
ConvertGradeToPoints(grade); //...
As it stands, your code is undreadable. Please edit and add java tags around it. [ highlight=Java] your code [/highlight]. remove the space before highlight=Java to get them to work.
your code
You may notice that you have a scanner implemented in your forloop, but nothing ever scans in to fill it. In other words, "numguess" is null, so doesn't meet the requirements of any of your if...
add java tags please
Thanks guys, I went with the UML diagram I had already made for the project and added a gui class to it. Should be good enough for now :)
in response to: But how do you add or subtract them? Specifically, within my program there's a method that states you need to find the change within the two population arrays. All in all, I do...
How about posting what you already have so we don't have to start from scratch? It will be way easier to help you edit your own code than writing it from scratch ourselves.
Also a few places you...