Search found 77 matches

by Niaz
Thu Nov 24, 2005 10:42 am
Forum: Volume 109 (10900-10999)
Topic: 10942 - Can of Beans
Replies: 9
Views: 4644

I am still getting wrong answer. All the outputs provided by Raj matched with mine. Please give me some tricky input so that I can fix my bug. Thanks in advance.
by Niaz
Thu Nov 24, 2005 10:37 am
Forum: Volume 109 (10900-10999)
Topic: 10934 - Dropping water balloons
Replies: 12
Views: 6437

Now the problem is clear to me. But, still have one more question about the solution. How did you find that the starting position would be 14! Would you please explain a little about your algorithm? As the solving rate is very high, I guess, this is an easy problem but stuck over there. :oops:
by Niaz
Sat Oct 22, 2005 4:57 pm
Forum: Volume 109 (10900-10999)
Topic: 10942 - Can of Beans
Replies: 9
Views: 4644

Saif's Input 52 1073741823 99 1 2 3 0 2 29 41 5 11 68 19169 7 9 25 26962 6 2 65 23281 12 11 28 2995 1 23 43 32391 10 28 5 292 9 31 83 19718 7 23 96 14771 5 10 39 25667 7 17 100 28703 10 13 12 17673 8 14 65 28253 9 4 69 32662 8 12 58 8723 11 2 42 12316 14 3 36 288 15 5 7 19264 29 3 49 15890 6 11 30 1...
by Niaz
Sat Oct 22, 2005 4:55 pm
Forum: Volume 109 (10900-10999)
Topic: 10942 - Can of Beans
Replies: 9
Views: 4644

Hi Saif, Here is the output for ur input. Hope it helps. Good Luck. -1 99 01 02 00 02 29 68 05 11 07 09 25 65 02 06 11 12 28 43 01 23 05 10 28 -1 96 07 23 39 05 10 10 12 13 65 08 14 69 04 09 58 08 12 42 02 11 36 03 14 05 07 15 49 03 29 06 11 30 02 10 15 22 01 24 41 11 30 01 09 14 24 06 25 83 10 19 ...
by Niaz
Sat Oct 22, 2005 1:52 pm
Forum: Volume 109 (10900-10999)
Topic: 10934 - Dropping water balloons
Replies: 12
Views: 6437

Same problem here... waiting.....
by Niaz
Sat Oct 22, 2005 10:37 am
Forum: Volume 3 (300-399)
Topic: 392 - Polynomial Showdown
Replies: 93
Views: 18175

I am trying to solve this problem for the last 3 years ! But getting again and again WA !!! I have tried all the test inputs and outputs given in the board. My WA code can produce correct output for all the given inputs. What can I do now ? Is there any one who can help me ? If any interested person...
by Niaz
Sun Oct 09, 2005 3:20 pm
Forum: Volume 102 (10200-10299)
Topic: 10279 - Mine Sweeper
Replies: 102
Views: 28493

It looks an easy one but its pulling my brain out by showing WA again and again. Plz check my code and do some comment. Another thing, will there be any blank line after the last case ? Code #include<stdio.h> char grid[20][20],extra[20][20]; void putmine(int n) { int i,j; for(i=0;i<n;i++) for(j=0;j<...
by Niaz
Fri Oct 07, 2005 9:20 am
Forum: Volume 106 (10600-10699)
Topic: 10617 - Again Palindrome
Replies: 12
Views: 5889

I do also understand the problem. But feeling uneasy to solve ! From another thread, I came to know that this problem can be solved by using DP. But I am really very weak in DP. Is there any one who can tell me the procedure of solving this problem using DP ? Is it an Edit Distance problem ? Waiting...
by Niaz
Fri Oct 07, 2005 9:11 am
Forum: Volume 106 (10600-10699)
Topic: 10658 - ReArrange
Replies: 16
Views: 5846

Miras, would u plz give some hints about finding the FORMULA ?
Thanks in advance...
by Niaz
Wed Oct 05, 2005 5:56 pm
Forum: Volume 108 (10800-10899)
Topic: 10871 - Primed Subsequence
Replies: 20
Views: 12250

Thanks Bijon for ur effort. But still I am getting WA! Here is my outputs accourding to ur inputs. Shortest primed subsequence is length 2: 5 6 Shortest primed subsequence is length 3: 4 5 4 This sequence is anti-primed. Shortest primed subsequence is length 2: 6369 9734 Shortest primed subsequence ...
by Niaz
Tue Oct 04, 2005 8:47 am
Forum: Volume 109 (10900-10999)
Topic: 10924 - Prime Words
Replies: 44
Views: 22470

Jalal, u did the same thing that i did ! In the contest some time one WA can force a team to go down by 10/20 places. So, this thing has to be solved. If any problem setter takes 1 as prime, then he/she must put that information in the problem. I hope, in future, all the problem setters will keep th...
by Niaz
Tue Oct 04, 2005 8:42 am
Forum: Volume 108 (10800-10899)
Topic: 10871 - Primed Subsequence
Replies: 20
Views: 12250

Actually My siv is fast enough to find mentioned primes. And if the input in 1000 10000 then the sum of the numbers will be really very high. That's why i did find the prime at such a high range.

Can any one give me some Input and Output so that I can check my code with them.

Thanks.
by Niaz
Mon Oct 03, 2005 8:23 am
Forum: Volume 108 (10800-10899)
Topic: 10871 - Primed Subsequence
Replies: 20
Views: 12250

Please give some I/O.
I have generated prime upto 30000010 and then got WA. Is it due to upper bound or for some other reason ? Is there any tricky input ? plz help.

Thanks in advance.
by Niaz
Mon Oct 03, 2005 5:55 am
Forum: Volume 109 (10900-10999)
Topic: 10924 - Prime Words
Replies: 44
Views: 22470

The number 1 is a special case which is considered neither prime nor composite (Wells 1986, p. 31). Although the number 1 used to be considered a prime (Goldbach 1742; Lehmer 1909; Lehmer 1914; Hardy and Wright 1979, p. 11; Gardner 1984, pp. 86-87; Sloane and Plouffe 1995, p. 33; Hardy 1999, p. 46)...
by Niaz
Mon Oct 03, 2005 5:53 am
Forum: Volume 109 (10900-10999)
Topic: 10924 - Prime Words
Replies: 44
Views: 22470

I didn't consider 1 as a input (even i didn't read the problem totally) and got Acc. Then after watching this post, I opened my code and see that my BANGLA TYPE prime finding algo is covering one as a PRIME !!!. int isPrime(int num) { if(num == 2 || num == 3 || num == 5) return 1; for(long i=2;i<=sq...

Go to advanced search