I read a lot about that, and I feel like since we haven't learned about it, that's not what is expected in the program. My algorithm may not be the most efficient, but it seems like it should make...
Type: Posts; User: TommyFiz
I read a lot about that, and I feel like since we haven't learned about it, that's not what is expected in the program. My algorithm may not be the most efficient, but it seems like it should make...
I'm getting the following error. The idea is to have the user input a number, and then print out all the primes less than the number.
Enter a value:
9
Exception in thread "main"...
Today in class I was wondering why he STILL wasn't talking about arrays and the assignment was due on Friday, and I found out I actually skipped a chapter and just assumed we were supposed to do the...
Sorry, I forgot to attach code
while(!"quit".equals(input)){
System.out.println("Please enter a name: ");
personName[x] = keyboard.nextLine();
input = personName[x];
if(input ==...
I tried to understand what you were saying, and this is where I'm at now. I haven't got as far as making another class, thats going to be a whole nother story.
Anyways, why isn't the if statement...
The goal for this project was to allow a user to input the name and age of a person, as many times as they want, until they type "quit". After they type quit, the program is to print the name and...
Dalisra, thank you! Removing static from my variables worked perfectly.
I didn't quite understand your explanation of fixing the formula at the end, but the assignment states "assuming all...
Thanks for that! No, I do see why, but that isn't the problem in this case. Well, it may be ONE problem, but not THE problem. When I run the program I make sure to enter different ages, and it's...
I'm having another problem with a homework assignment. We have to have 2 classes, one has the main program and the other has all the methods for the data received in the first class. Here is what I...
Awesome that worked. Thanks for the fast reply!
I'm supposed to create a program that Asks for 3 names, as well as their age. It should ask one name, then their age, then the next and so on. When I compile this program, here is what happens.
...