Search Results

Showing results 1 to 40 of 1000
Search took 0.13 seconds.
Search: Posts Made By: Ezzaral
Forum: Geeks' Lounge 3 Hours Ago
Replies: 305
Views: 21,720
Posted By Ezzaral
Old German metal from my high school days: Helloween - I'm Alive (http://www.youtube.com/watch?v=OiZoGwXcP50)
Drummer can really work the double bass :)
Forum: Java 5 Hours Ago
Replies: 13
Views: 9,021
Posted By Ezzaral
Don't hijack threads with new questions. Start a new thread of your own.

And the answer to your second question is no.
Forum: Java 9 Hours Ago
Replies: 5
Views: 166
Posted By Ezzaral
Let's say your fares were in an array fares[3][]. Then your option group index directly corresponds to a fare scheduleselectedFare = fares[optionIndex];No need for a switch. The rest of your code...
Forum: Java 1 Day Ago
Replies: 16
Views: 222
Posted By Ezzaral
The "test" array has nothing at all to do with your code. It's just an array I used to put some data in so you could see how to use the formatted output hereSystem.out.printf(" %s | %s | %s...
Forum: Java 1 Day Ago
Replies: 16
Views: 222
Posted By Ezzaral
No, that part is up to you. I think my example comes plenty close. Anything more is essentially doing that part of your assignment for you.
Forum: JavaScript / DHTML / AJAX 1 Day Ago
Replies: 2
Views: 114
Posted By Ezzaral
Ok congratulations, you've demonstrated that you can paste your homework. Do you have any specific questions? Anything at all to show that you have given this the least bit of thought?
Forum: Java 2 Days Ago
Replies: 6
Views: 157
Posted By Ezzaral
Learn manners first.
Forum: Java 2 Days Ago
Replies: 9
Views: 127
Posted By Ezzaral
Directly from the source: http://java.sun.com/docs/books/tutorial/java/package/index.html
Forum: Java 2 Days Ago
Replies: 9
Views: 127
Posted By Ezzaral
If you haven't specified a modifier and they are in a different package, they are private.

Use a public method getName() to get the name - don't access the variable directly.
Forum: Java 2 Days Ago
Replies: 5
Views: 166
Posted By Ezzaral
Just have an int[] array variable like "selectedFares[]" that points to the correct fare array. Your stateChanged method just needs to set it when they choose one, i.e.switch (option) {
case 0:
...
Forum: Java 2 Days Ago
Replies: 9
Views: 127
Posted By Ezzaral
If you have declared it private then you will need to use a public getter method to get the name. Same for balance.
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
You don't need a class name to call static methods within the same class - and that class name doesn't match anyway.

Also, make sure your method call matches the signature you wrote. You can't...
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
It has to be inside the class. Just declare it after main(). It should return a String.public static String getCityName() {after you get a value from the user, return that value;
Forum: Java 2 Days Ago
Replies: 9
Views: 127
Posted By Ezzaral
Well, move it outside main(). Cut-paste the entire thing outside of the braces that delimit the main() method.
Forum: Java 2 Days Ago
Replies: 2
Views: 88
Posted By Ezzaral
No, you don't put javadoc comments inside methods.

Edit: On an unrelated note, "Number" would be a really bad name for a boolean variable. Number is the base class for numeric wrapper classes like...
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
Don't put it in a separate class. It doesn't really have any context as a separate object.

Just make a method getCityName() that returns the String that the user entered.
Forum: Java 2 Days Ago
Replies: 9
Views: 127
Posted By Ezzaral
You can't declare methods inside other methods. Get consolidate() out of main().
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
"case" is not capitalized.
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
Move your switch down below the point you are getting the input. You want to set the speed based on what they input and you want to switch on the first char of that entryswitch(roadChoice.charAt(0))...
Forum: Java 2 Days Ago
Replies: 2
Views: 2,308
Posted By Ezzaral
That is because it has nothing to do with Java itself. You're just sending a DDL statement to the database. Any difficulties with it would be specific to that database and the JDBC driver.
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
A and B are not variables themselves. They are two possible values for a variable that you want the user to set. So use a String variable for roadChoice that you read the input into. Then you can use...
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
Just like you got the other input, but you will need to use something like charAt (http://java.sun.com/javase/6/docs/api/java/lang/String.html#charAt(int))(0) to get the first character of the String...
Forum: Java 2 Days Ago
Replies: 5
Views: 7,877
Posted By Ezzaral
Yes, you are missing the fact that this is someone else's two year old thread and it's in Java, not C++.
Forum: Java 2 Days Ago
Replies: 1
Views: 92
Posted By Ezzaral
You don't need to re-create all of those things when you pick another file for the table. Just create a new table model from that file and use setModel()...
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
No. Change the value of speed separately from your print output.
Forum: Java 2 Days Ago
Replies: 4
Views: 174
Posted By Ezzaral
You misspelled listener.
Forum: Java 2 Days Ago
Replies: 16
Views: 13,935
Posted By Ezzaral
Hmm, wrong language and 'void main()'... batting zero so far.
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
For A and B you could use char values, but not string values in the switch. If you use a String, you would have to use if() statements.
Forum: Website Reviews 2 Days Ago
Replies: 1
Views: 81
Posted By Ezzaral
All of the image links are broken, so I would have to say... no.
Forum: Java 2 Days Ago
Replies: 20
Views: 213
Posted By Ezzaral
Just have the user enter a number for the road type. Then your switch can simply be switch (roadType) {
case 1:
speed = 50;
break;
case 2:
// ... etc
}You will have to remove...
Forum: DaniWeb Community Feedback 3 Days Ago
Replies: 22
Views: 907
Posted By Ezzaral
Get riled up easily much?

This isn't me in "shook my cage" mode. You were suggesting that if the system has no value at all, it should be scrapped. I merely pointed out that only a few have voiced...
Forum: DaniWeb Community Feedback 3 Days Ago
Replies: 6
Views: 231
Posted By Ezzaral
She's still about. Just a couple of days ago she popped in for this post in classic form: http://www.daniweb.com/forums/post1047754.html#post1047754
Forum: Java 3 Days Ago
Replies: 14
Views: 260
Posted By Ezzaral
If "unsorted" contains any duplicates, yes. It just can't retrieve the same element from "unsorted" more than once. The first version could use unsorted.get(4) multiple times if 4 came up as the...
Forum: Java 3 Days Ago
Replies: 14
Views: 260
Posted By Ezzaral
It's actually removing the element from "unsorted". It grabs an element randomly between 0 and size()-1.
Forum: Java 3 Days Ago
Replies: 16
Views: 222
Posted By Ezzaral
Yes, those two lines are an example. As you said, you need to use theBoard[][].
Forum: Java 3 Days Ago
Replies: 14
Views: 260
Posted By Ezzaral
If you don't want repeat selections, you can use this insteadkeys_Array[i] = (Integer) unsorted.remove( random.nextInt(unsorted.size()) );
Forum: Legacy and Other Languages 3 Days Ago
Replies: 3
Views: 157
Posted By Ezzaral
Sounds like a job for Google.

You could start with this: http://en.wikipedia.org/wiki/Comparison_of_programming_languages
Forum: Java 3 Days Ago
Replies: 16
Views: 222
Posted By Ezzaral
Those are the array indexes. "test" was just a small String array.
Forum: Java 3 Days Ago
Replies: 14
Views: 260
Posted By Ezzaral
You have to cast the Object to Integer if you want to assign it to the array.keys_Array[i] = (Integer)unsorted.get(random.nextInt(100));Using generics to type your collections would avoid that.
Forum: Java 3 Days Ago
Replies: 14
Views: 260
Posted By Ezzaral
for(int i=0;i<100;i++){
keys_Array[i] = unsorted.get( random.nextInt(100) );
}Note that get() is used if 'unsorted' is an arraylist and not an array.
Showing results 1 to 40 of 1000

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC