Search:

Type: Posts; User: silverdemon; Keyword(s):

Search: Search took 0.01 seconds.

  1. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    yeah, me too. I like to program a few simple things every once in a while...

    _count_ me in (pun intended)
  2. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    yeah, what I meant was that you want to keep the loop for counting as small as possible. At first I had another line of code in my loop, I believe that was for displaying the number 'líve'. I took a...
  3. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    That's true. I wanted to make the program as fast as I could, so I got every bit of code outside of the loop. Only the real counting takes place inside the loop. This way the loop will be smaller and...
  4. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    ok, here is the snippet of code that does the counting in my VB6 program. There are also comments at the end of all lines (did that for XcOM so he could see what I was doing)


    Private Sub...
  5. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    Yeah, who won?

    I can see that VB (my program:)) wins in the shorter countings, but java (trace) takes over at the larger numbers. Also C++ (Mtekk) is quicker at those numbers.
    It seems to me that...
  6. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    oh boy, oh boy! can't wait!
    I'd really like to see how fast is actually possible...

    btw XcOM, you've got a little typo in my name ;)
  7. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    Hmm, in that case I would most definately like to know if my mail actually was sent.

    When I tried to send an *.exe file I got a message that for safety things... bla bla... could not send message....
  8. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    that would be a good idea (may for future contests though ;) )



    What I did to send all the files (including *.exe files) is zipping all the files just as you normally would do, and then change...
  9. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    Hmm, probably depends on how you save your numbers. Java could be slower than VB6, but I think C or C++ should be even faster than basic... since I don't have a lot of experience in C I won't enter...
  10. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    I can count to a googol no problem, but when you try to save the file (or any other way of saving) I get the 'problem' of not enough memory. as you could see in my previous post it cuts off at about...
  11. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    did some major improvement, still no output file, but here are the results:
    (VB6.0, C2D E8400)
    100K: 2ms
    1M: 23ms
    10M: 238ms
    100M: 2412ms
    1B: 24195ms

    these times seem pretty fast for me, so...
  12. Thread: Counting

    by silverdemon
    Replies
    112
    Views
    83,387

    Re: Counting

    ok, I altered my code a bit, now getting:

    1M: 1044ms
    5M: 5186ms

    I've got no output file though, do I need to redo this and make an output file?

    (using VB6.0 btw, and an intel C2D E8400)
Results 1 to 12 of 12