I'm new to java, and I'm making a rock paper scissors program. I can't figure out how to make a loop that runs my program fifteen times and then it stops. I came up with this :
while(replay <16 (!nextLine.equals("end")){
But it doesn't work. Help?
Printable View
I'm new to java, and I'm making a rock paper scissors program. I can't figure out how to make a loop that runs my program fifteen times and then it stops. I came up with this :
while(replay <16 (!nextLine.equals("end")){
But it doesn't work. Help?
Still need help.
Why does everyone ignore this?
you hardly waited an hour...
you obviously asked this question in the hope of getting a fast awnser, where you have to do very little effort...
what have you looked up so far?
what do you know of java programing?
@liluma
I just started two weeks ago, and I couldn't find anything on google.
And how does two hours and 14 minuets count as "hardly an hour"?
you should know that nobody is forced to awnser...
you said after 33 mins that everybody is ignoring your post... <== this doesn't make people want to help you. ;)
just saying
and since you just started with java search up the basics. ;)
learn what is the difference between while, do while, and for loops
and what exactly they do
take a look at this site. ;)
The Really Big Index
this should have everthing explained, from the basics to the somewhat more advanced stuff.
grtz liluma
"it doesn't work" is not terribly helpful.
Are you getting compiler errors?
If so then post the complete text of them.
Does it compile?
Then post any exceptions you get when running them (in full), highlighting the line in your code where they occur.
No exceptions?
Then explain what your program is doing and what it should be doing, including relevant code.
When posting code please wrap it in [code] tags [/code] in order to retain the formatting.