Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~846 People Reached
Favorite Forums
Favorite Tags
java x 11
Member Avatar for srthomso

I have some code which examines an array to see if it contains a particular value: boolean found = false; int []a = new int[100]; populate(a); // populates the array a with a set of random values int valueToFind = 123; // or whatever we want to find while((n < …

Member Avatar for srthomso
0
314
Member Avatar for srthomso

Could anyone give me a hand with my mock exam, i'm on msn - [email]get_jiggy_widit@hotmail.com[/email]. I'm struggling a bit - with some of the simple things really n it's getting on my nerves. Any help would be greatly received. Thanks Steve

Member Avatar for srthomso
0
134
Member Avatar for srthomso

code: public static void menu(){ String reply; System.out.println("Make your choice:"); reply = getLineFromUser(); //assume this function works correctly if(reply.equals("play")){ playgame(); } else if(reply.equals("end")){ stopGame(); } menu(); // recursive call. Don't use!!!!! Any ideas? i struggle with while loops at the best of times.

Member Avatar for bvvkrishna
0
145
Member Avatar for srthomso

I've come up with some code to try and reject ages outside the range of 18 to 64, but i cant seem to find my errors or how to fix it. Feel stupid as its probably somethin easy, but i'm just learnin the language, can you help: int age; age …

Member Avatar for srthomso
0
117
Member Avatar for srthomso

here's the code: string reply; reply = getLineFromUser(); //assume this function works correctly if(reply == "JAVA"){ System.out.println("OK to continue"); } else { System.out.println("Error - try again!"); } i cant seem to see where i'm going wrong, thus cant get a correct version to work. I need it to keep repeating …

Member Avatar for srthomso
0
136