For a not equal function, it should be as simple as !reply.equals("yes"). I believe the ! inverter works with all boolean arguments, so there's always a way to work it into an if statement.
Also,...
Type: Posts; User: Iantaylora
For a not equal function, it should be as simple as !reply.equals("yes"). I believe the ! inverter works with all boolean arguments, so there's always a way to work it into an if statement.
Also,...
I'm somewhat new to Java myself, but one possibility is that your != function isn't designed to work with Strings. Try the function "reply.equals("yes")" or the more useful...
Well, I took some of your advice as far as OOP, and made a unitStats class which knows its own stats, etc, and then I build the unit by giving it its race and two classes. These values provide the...
Alright, so some of you may remember me from the other day, when I needed help fixing for loops and using a Scanner. Things have come a long way since then, and my code is largely functional! My next...
Can you explain a little bit more about what you mean by "this shape"? If you want code that prints that exact output, what you probably want to do is make two for loops, inside of each other, so...
Andbin, that makes perfect sense, thanks so much! It completely solved my problem. If I run into further issues, should I start a new thread or should I edit the OP for this one, or what is the...
Hello all,
I'm a new member and relatively new to Java; I took two years in high school but that was about four years ago. I'm making a turn based strategy game based on Final Fantasy Tactics and...