What is ur minimum time to generate prime in 20000000 ?

Post about everything you want - even if it is not related to programming or this site.

Moderator: Board moderators

mohiul alam prince
Experienced poster
Posts: 120
Joined: Sat Nov 01, 2003 6:16 am
Location: Dhaka (EWU)

What is ur minimum time to generate prime in 20000000 ?

Post by mohiul alam prince »

Hi
There are lot of prime problem's in this site. But my questain is only prime generation. Because most of the good programmer's are use other technick to solve this type of problem's. I want to know what is the minimum time to generate prime in 20000000(only marked this are the prime) ?

U can mesure ur time by using uva submit script. I have known my prime generation time by this way. I have submit only my prime generation code
and my problem was 10394. To mesure my time i have used only prime
generation code not the problem's solution.

I want to know who take the minimum time to generate prime in 20000000. :D

what ever ur time ? please mention it if u have enough time. :D

MAP
shamim
A great helper
Posts: 498
Joined: Mon Dec 30, 2002 10:10 am
Location: Bozeman, Montana, USA

Post by shamim »

Mohiul, Maybe it would be better if you mentioned your prime generation time. :wink:
mohiul alam prince
Experienced poster
Posts: 120
Joined: Sat Nov 01, 2003 6:16 am
Location: Dhaka (EWU)

Post by mohiul alam prince »

shamim vi
my prime generation time is 1.523 for 20000000.
But u don't mention ur time. :D

MAP
sohel
Guru
Posts: 856
Joined: Thu Jan 30, 2003 5:50 am
Location: New York

faster

Post by sohel »

My prime generation time is slightly quicker..
.. it takes 1.482 seconds for 20000000.
mohiul alam prince
Experienced poster
Posts: 120
Joined: Sat Nov 01, 2003 6:16 am
Location: Dhaka (EWU)

Post by mohiul alam prince »

Hi
I don't want any type of prove of ur algorithm, but I belive u will mention ur proper time. :)

MAP
Kamanashish
New poster
Posts: 10
Joined: Wed Dec 17, 2003 3:12 pm
Location: Dhaka
Contact:

Post by Kamanashish »

Hi Mohiul.

Why r u so sure that the time of sohel is not real .
Work hard.
mohiul alam prince
Experienced poster
Posts: 120
Joined: Sat Nov 01, 2003 6:16 am
Location: Dhaka (EWU)

Post by mohiul alam prince »

Hi
what is ur time please tell ?
I don't mean that sohel's time is worng(Sohel is my class mate so I know his ability he has solve about 860 problem's in uva) only i want to know the time.
I hope u will mention ur time.

MAP
Last edited by mohiul alam prince on Sun Feb 27, 2005 3:03 pm, edited 1 time in total.
Kamanashish
New poster
Posts: 10
Joined: Wed Dec 17, 2003 3:12 pm
Location: Dhaka
Contact:

Post by Kamanashish »

Sorry mohiul.

Sohel told you his time, but u didnot belive it and told him for real one.
Now if i tell u my time then u may also not belive my time. So....

:o
Work hard.
A1
Experienced poster
Posts: 173
Joined: Wed Jan 28, 2004 3:34 pm
Location: Bangladesh

Post by A1 »

Better u talk about your algorithm(method) then to say my time is 0.0somthing
If one say false time, you can not prevent him/her because you don't know every one personally!!
mohiul alam prince
Experienced poster
Posts: 120
Joined: Sat Nov 01, 2003 6:16 am
Location: Dhaka (EWU)

Post by mohiul alam prince »

Hi
A1 and Kamanashish forget every thing.
please mention ur time.
i want to know who is the good prime generator and what is his time that
i can understand my real position in prime generation. :)

MAP
mohiul alam prince
Experienced poster
Posts: 120
Joined: Sat Nov 01, 2003 6:16 am
Location: Dhaka (EWU)

Post by mohiul alam prince »

HI
Is this possible to generate prime in 20000000 below .200 second. :o

MAP
shamim
A great helper
Posts: 498
Joined: Mon Dec 30, 2002 10:10 am
Location: Bozeman, Montana, USA

Post by shamim »

ok Mohiul, now that you ask..

my time is: 0:05.662 sec
Guest
New poster
Posts: 39
Joined: Wed May 19, 2004 5:52 pm
Location: Dhaka, Bangladesh
Contact:

Post by Guest »

Mine is 2.640 Secs
stubbscroll
Experienced poster
Posts: 151
Joined: Tue Nov 16, 2004 7:23 pm
Location: Norway
Contact:

Re: What is ur minimum time to generate prime in 20000000 ?

Post by stubbscroll »

mohiul alam prince wrote:Hi
I want to know who take the minimum time to generate prime in 20000000. :D

what ever ur time ? please mention it if u have enough time. :D

MAP
How do you find out the time spent for generation of primes only? My time for problem 10394 is 2.373 sec, but I don't know how much time the input/output takes.

edit: now I saw that you submitted the prime generation code only to determine the time. How much time was spent at I/O? If you can tell us it, you will save us a lot of WA submissions. :D
A1
Experienced poster
Posts: 173
Joined: Wed Jan 28, 2004 3:34 pm
Location: Bangladesh

Post by A1 »

My time is not as good as shole or prince.
My sieve pirme code runs about 03.500sec in P-III 600Mhz computer(run time highly depends on computer config)
i test my codes run time by this following code:

Code: Select all


start=clock();
sieve_prime(1,20000000);
edn=clock();

coderun=(double)(start-end)/CLOCKS_PER_SEC;

printf("%lf\n",coderun);

Post Reply

Return to “Off topic (General chit-chat)”