Search found 16 matches
- Fri May 28, 2004 7:21 pm
- Forum: Volume 105 (10500-10599)
- Topic: 10530 - Guessing Game
- Replies: 57
- Views: 29498
- Fri May 28, 2004 6:46 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10023 - Square root
- Replies: 121
- Views: 30516
- Mon May 24, 2004 10:01 am
- Forum: Volume 105 (10500-10599)
- Topic: 10583 - Ubiquitous Religions
- Replies: 33
- Views: 15568
10583....WA.....sample input needed
I think my algorithm to solve this problem is very simple and correct (i hope). :roll: but it generates WA. :roll: can someone please help me finding the problem or giving me more sample input so i can check. Here is my code [c] #include<stdio.h> void religion_count(long n,long m); long tot; main() ...
- Fri May 07, 2004 5:28 pm
- Forum: Volume 101 (10100-10199)
- Topic: 10131 - Is Bigger Smarter?
- Replies: 93
- Views: 68744
10131.....WA
The same old problem.......WA :roll: Can somebody help me? Here is my code: [c] #include<stdio.h> struct list{ int w; int s; int c; }; void Longest_sequence(void); void Qsort(int p, int r); int Partition(int p, int r); void display(int i); int total,count; int length[1100],predecessor[1100]; struct ...
- Fri Apr 23, 2004 7:35 pm
- Forum: Volume 4 (400-499)
- Topic: 497 - Strategic Defense Initiative
- Replies: 144
- Views: 24666
497......RTE(SIGSEGV)
My code generates Run Time Error (SIGSEGV). Very common error for this problem, i know. I think i've used sufficiently large array. Can someone please help me to get rid of this problem? I am just fadeup :cry: :roll: :x Here is my code [c] #include<stdio.h> #include<string.h> #include<stdlib.h> void...
- Wed Apr 21, 2004 12:03 pm
- Forum: Volume 102 (10200-10299)
- Topic: 10226 - Hardwood Species
- Replies: 121
- Views: 41728
Well Larry.......you adviced me to check the input portion....well, but it works fine with my sample input file and generates correct output. If you see carefully, you can realize it can handle more than one blang line between two dataset. Well.......thanks for your reply......i am trying to take in...
- Tue Apr 20, 2004 5:26 pm
- Forum: Volume 102 (10200-10299)
- Topic: 10226 - Hardwood Species
- Replies: 121
- Views: 41728
10226......TLE
My code causes TLE. I cannot find out the reason. I used Quick sort algorithm to sort the tree names and then start scan though the list and keep counting. It doesn't require any searching algorithm. But it causes mysterious TLE. Can somebody find out the problem? :o My code is given below [c] #incl...
- Sat Apr 03, 2004 9:15 am
- Forum: Volume 4 (400-499)
- Topic: 412 - Pi
- Replies: 104
- Views: 20598
412.....WA
[c] #include<stdio.h> #include<math.h> int gcd(int x,int y); main() { int n,i,j,pair,count,ratio,val[100]; float pi; while(1) { scanf("%d",&n); if(n==0) break; for(i=0;i<n;++i) scanf("%d",&val ); pair=0;count=0; for(i=0;i<n-1;++i) for(j=i+1;j<n;++j) { ratio=gcd(val ,val[j...
- Thu Apr 01, 2004 5:29 pm
- Forum: Volume 4 (400-499)
- Topic: 495 - Fibonacci Freeze
- Replies: 222
- Views: 36667
- Wed Mar 31, 2004 12:19 pm
- Forum: Volume 4 (400-499)
- Topic: 495 - Fibonacci Freeze
- Replies: 222
- Views: 36667
495.....TLE...PLEASE HELP
I got TLE....i think my addition is correct. i check for many outputs including 5000.....and i found it correct....but l got TLE. I precalculate the numbers and store it and then just ouput according to the input. Can anybody find out the problem please. Better copy this code and run and figure out ...
- Fri Mar 26, 2004 10:11 am
- Forum: Volume 101 (10100-10199)
- Topic: 10101 - Bangla Numbers
- Replies: 122
- Views: 31569
- Wed Mar 24, 2004 7:54 pm
- Forum: Volume 101 (10100-10199)
- Topic: 10110 - Light, more light
- Replies: 76
- Views: 28595
- Tue Mar 23, 2004 11:20 am
- Forum: Volume 101 (10100-10199)
- Topic: 10110 - Light, more light
- Replies: 76
- Views: 28595
- Tue Mar 23, 2004 7:23 am
- Forum: Volume 101 (10100-10199)
- Topic: 10110 - Light, more light
- Replies: 76
- Views: 28595
10110....WA
This is one of the easy problem as far as i know........is it really????.....hmmmmm......but it always gives me wrong answer.......why???[c] #include<stdio.h> #include<math.h> main() { long n,s; while(1) { scanf("%ld",&n); if(n==0) break; s = (long)sqrt(n); if(s*s==n) printf("yes\...
- Tue Mar 23, 2004 7:13 am
- Forum: Volume 101 (10100-10199)
- Topic: 10101 - Bangla Numbers
- Replies: 122
- Views: 31569
10101...WA...please help
This code generates wrong answer......but i don't know why.......i think its ok......is there any input which include white space between two digits of a number???? please help.[c] #include<stdio.h> #include<string.h> void generate_string(char *num, char ch); char str[100],temp[100]; int count; main...