Posts
 
Reputation
Joined
Last Seen
Ranked #3K
Strength to Increase Rep
+0
Strength to Decrease Rep
-0
80% Quality Score
Upvotes Received
3
Posts with Upvotes
3
Upvoting Members
3
Downvotes Received
1
Posts with Downvotes
1
Downvoting Members
1
1 Commented Post
0 Endorsements
Ranked #3K
~11.1K People Reached

21 Posted Topics

Member Avatar for smachee

You need a constructor in your program, which you don't have. So, you want a method with the same name as your class, that accepts an array as an argument. Here's a little more on constructors: [url]http://java.sun.com/docs/books/tutorial/java/javaOO/constructors.html[/url] Also, you want a method that returns an average of the test scores. …

Member Avatar for patrick_25
0
5K
Member Avatar for melissa2185

You should look up classes in Java, their methods, and constructors. I'll give you a basic implementation of the Address class in order to get you started. What I have here is an Address class, with all of the variables you mentioned, and a constructor (the method with the same …

Member Avatar for Ezzaral
2
269
Member Avatar for happygeek

I'm not really expecting any new toys this Christmas. I did finish a networked tetris game I was working on yesterday, and I just got virtualbox for my mac. That's good enough I guess.

Member Avatar for mitch9654
0
322
Member Avatar for mellowmike

I wasn't sure whether to put this question here or in the Windows section, but I was wondering if there was a way to put images into a Visual C++ project. That way, I won't have to load an image from an outside directory, and it will already be in …

0
64
Member Avatar for RoyaLPearL

Your conditions for your if statements are doubles, which doesn't make any sense. You should be trying to verify a condition in if and else if statements, so putting a double from an array of doubles like if(price[0]) won't work.

Member Avatar for mellowmike
0
165
Member Avatar for mellowmike

So I have a client/server application and I'm trying to send an ArrayList of objects to the server. I kept getting errors sending the ArrayList of objects, so I just decided to send an empty ArrayList to see if anything was wrong, and it turns out, that the server can't …

Member Avatar for mellowmike
0
490
Member Avatar for balloonbob

Could you give us the error message? The java compiler usually tells you what line a NullPointerException is on, and that could help with debugging. Also, you should use [code] tags to make your post more readable.

Member Avatar for mellowmike
0
175
Member Avatar for happymadman

Did you initialize w? What are the weird numbers that are printing out? Could you post more of the code?

Member Avatar for happymadman
0
123
Member Avatar for confusedndazed

I compiled your code and ran it, and it showed the average. I'm not sure why you aren't seeing it. If you want to do a function call, the help jonsca provided should be sufficient, but from what I can tell, your code is working fine now.

Member Avatar for jonsca
0
95
Member Avatar for cam875

Do you need the catch IOException in the loop? Doesn't the one outside of the loop take care of the same thing? Maybe that's your problem.

Member Avatar for mellowmike
0
101
Member Avatar for ahmedshayan

The toString() method has public access privileges which you can't change. If you want to override it, you need to make your method public as well. Also, the toString method returns a String, while yours returns void. Change your method name to: public String toString(). And return a String in …

Member Avatar for ahmedshayan
0
343
Member Avatar for xxPoseidonxx

Could you post the Scorer class? I can't really find anything wrong with what you've done, but maybe a look at the other class will help.

Member Avatar for shubhinetwork
0
122
Member Avatar for Member #669917

It sounds like you just want to access some fields form this class? So I guess in the date class, you would just construct a new Patient object and access the date of birth with the getDOB() method: Patient p = new Patient(......); String birth = p.getDOB();

Member Avatar for mellowmike
0
185
Member Avatar for beforetheyknew

You can construct a stringbuffer from the string you want to modify, then use the insert method to insert a "." in the desired place. Then use the stringbuffer's toString() method to convert it back to a string. You can't put decimals in integers.

Member Avatar for cale.macdonald
0
74
Member Avatar for richman0829

Well, I took out the PI constant, and everything worked. That might be your problem. Also, as the poster below me said, you have curly quotations on one of your lines.

Member Avatar for richman0829
0
163
Member Avatar for may781

You could use the args array you have, and have the imageLocation = args[0] where args[0] is the string entered right after the command to execute the program: java FinalExam imageLocationhere

Member Avatar for javaAddict
0
110
Member Avatar for intelnf09

Hi, so I compiled your code and got everything to work. You can keep the two files separate, that's fine. I'm not sure why you're getting the constructor error. Do you have the two files in the same directory? The only problem I found was how you were formatting the …

Member Avatar for intelnf09
0
1K
Member Avatar for zobadof

Remove the brace at line 3. You're just declaring functions, and that shouldn't be included in anything. Put int main() in front of the brace at line 10 and put a closing brace after the return 0.

Member Avatar for Nick Evan
0
2K
Member Avatar for cabosun

You have Tree t = new Tree(); but the class you defined is "tree" in lower case. Change the line to lower case "tree", or change the class to upper case.

Member Avatar for mellowmike
0
141
Member Avatar for kool005

Well, you have an array of LinkedLists, not an array of Strings. You can't just read the next line and put it into the array. You have to put it into the Linked List, which is in the array.

Member Avatar for mellowmike
0
154
Member Avatar for jh9t

For the isComplete() method, you can use the wordLength at the top. I would add an integer every time there was a correct guess and once the number of correct guesses equals the wordLength, return true.

Member Avatar for mellowmike
0
138

The End.