Type: Posts; User: java-noobette

Search: Search took 0.31 seconds.

  1. Ways to make this loop more efficient?

    Hello, this is a loop I've written to find all the prime numbers up to the input from the user (n)
    I can see that this one has many steps to perform and so I am looking for a way to improve it's...
  2. Replies

    Loops with boolean variables!

    I'm writing a complex for loop to find prime numbers. What I have so far is this:

    What I guess I'm trying to achieve is the rest of the loop...but I don't know how :confused:
    I'm going to...
  3. Re: Calculating time taken - does this look right? Error!

    I'm calling it from my main method, and I would really like to call it using System.err.println()

    At the moment, I can see that System.err.println(timeTaken()) means that I'll have to change...
  4. Calculating time taken - does this look right? Error!

    This is what the method I have written looks like.
    The error I get is 'void' type not allowed here, which I researched and learnt that: I am using a method that does not return a value in a place...
Results 1 to 4 of 4