No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
No I know that in order to compare a String you have to call its method .equals but how I check if a String is NOT equal to something? Will it be something like if ("hello" != String.equal())?? or is there a special method? I know I'm being dumb here … |
|
The basic difference would be interface cannot have any method definition or variables declared while an abstract method can have them. Now what is the difference between an abstract class and an interface when they contain only the method signatures in them. In what situations will you use either of … |
|
Hello friends, I am working on my final yr project using Java Swing. Now for the database part can anybody tell me which I should use among Servlets, Oracle or JSP or anything others. I mean which is currently used in industry at large. Hope to get advice. Regards Supratim |
|
I'm making a rock paper scissors game, and in this game there is a nested for loop so that the players challenge each other, the outer loop is supposed to loop through all the players starting with player 1, while the inner loop starts at the last player and moves … |
|
Can someone please tell me why "int can not be dereferenced" here. contents += cart[i].toString() + "\n [CODE]// ********************************************************************** // ShoppingCart.java // // Represents a shopping cart as an array of items // ********************************************************************** import java.text.NumberFormat; public class ShoppingCart { private int itemCount; // total number of items in the … |
|
Hey everyone. I am supposed to create a program that finds the area of a triangle...this i can do fine. My only problem is i was told that i need to use a get and set method to calculate the area. I dont exactly know how to use a get … |
|
Hi I'm doing a project in java.It is the game othello.It was all going well till i got an [B]ArrayOutOfBoundsException[/B]. the array is this buttons[9][9]; If you dont know othello it's a board game with an 8x8 board. The Exact error is "ArrayOutOfBoundsException: 9" and give the lines which the … |
|
Hi All, I have 2 classes. say Class A and Class B. My logic is coded in a method in class B. I am accessing this method of class B by creating an instance of class B in class A. To explain better: Class A{ ClassB b = new ClassB(); … |
|
hi, i was given this project to do in my java class but i dont exactly know what i have to do.... i understand that i need to create 2 classes, point that extends pair and labeledpoint that extends point.... but i have no idea what else the professor wants … |
|
import javax.swing.JOptionPane; public class cafe2 { public static void main(String args[]) { String name,ch; double price = 0.00; double sum=0.00; int cho=0; name=JOptionPane.showInputDialog("Enter Customer Name:"); do{ ch=JOptionPane.showInputDialog( " Food Name "+ "\n-----------------------------------------------------"+ "\n1) French Fries $ 3.50"+ "\n2) Fish and Chips $ 5.50"+ "\n3) Goat Cheese Pizza $20.70"+ "\n4) Chicken … |
|
[B][U]Good day to all programmers there!!!!,[/U][/B] [COLOR="Red"][U]please help me to my assignment, I need it tommorow! I want a program that [/U][/COLOR] [COLOR="Green"][B]1.input the name of student, 2.input his/her grades 3. display its grade rate 4. display if it is perfect, pased or failed[/B][/COLOR] :) |
|
I'm having all sorts of problems getting this program to work. I think I know what's wrong with it, but I don't know how to fix the problem. The program is supposed to read a text file that contains information like below.... 1 99 2 88 3 77 4 66 … |