Search found 7 matches

by anak_papua
Mon Mar 31, 2003 6:08 am
Forum: Volume 102 (10200-10299)
Topic: 10245 - The Closest Pair Problem
Replies: 92
Views: 10650

10245 - Output Limit Exceeded

why OJ gave my code Output Limit Exceeded? :evil: :evil: :evil: i didnt see anything that could give me that. [c] /*@JUDGE_ID: XXXXX 10245 C*/ #include <stdio.h> #include <math.h> #define MAX 10002 typedef struct { unsigned long x, y; } tdata; tdata data[MAX]; int main () { int jum, i, j; unsigned l...
by anak_papua
Fri Mar 21, 2003 4:51 am
Forum: Volume 100 (10000-10099)
Topic: 10038 - Jolly Jumpers
Replies: 445
Views: 79380

aha! how stupid i am!!!!
i didnt see such a simple thing. I got AC now.
Thank you very muchh :) :) :) :) :)
by anak_papua
Thu Mar 20, 2003 3:31 pm
Forum: Volume 100 (10000-10099)
Topic: 10038 - Jolly Jumpers
Replies: 445
Views: 79380

why must i change the data type for variable selisih? it is only array that contains only 1 or 0, to store whether the value of difference has been used or not. if i change to int, it wil just the same, but will use more memory because int use 2 bytes (4 bytes for GCC) , and char only one byte.
by anak_papua
Thu Mar 20, 2003 10:05 am
Forum: C
Topic: unsigned long long in C
Replies: 7
Views: 3049

aha.. i should initialize first, so that the output gave the same result, thank you :) :)
however i dont understand why we should initialize first, perhaps bugs?
i compiled it with GCC 2.95.3, FreeBSD 4.7 :)
once again thank you
:D :D :D :D :D :D
by anak_papua
Thu Mar 20, 2003 9:09 am
Forum: Volume 100 (10000-10099)
Topic: 10038 - Jolly Jumpers
Replies: 445
Views: 79380

10038 - Jolly Jumper WA

i'm sure this is an easy problem, but however i always got WA :( are there any special cases? i've handled for a sigle integer. [c] /*@JUDGE_ID: XXXXX 10038 C*/ #include <stdio.h> #include <string.h> #include <stdlib.h> #define MAX 3000 int main () { char isjolly, selisih[MAX], dif; long data[MAX]; ...
by anak_papua
Thu Mar 20, 2003 4:57 am
Forum: C
Topic: unsigned long long in C
Replies: 7
Views: 3049

unsigned long long in C

how to use unsigned long long in C? was my syntax error?
[c]
#include <stdio.h>

int main() {
unsigned long long a;

scanf ("%llu", &a);

printf ("%llu", a);
return 0;
}
[/c]

input :
1234567890

output :
2883627802384794322

how can this happened?

thanks before.
by anak_papua
Wed Mar 19, 2003 3:30 pm
Forum: Volume 4 (400-499)
Topic: 469 - Wetlands of Florida
Replies: 63
Views: 21197

i've fixed that problem and gave the same result as yours, but still WA. i dont know the mistake :( :( :( perhaps there are special cases or somethin that might trap me? [c]/*@JUDGE_ID: XXXXX 469 C*/ #include <stdio.h> #include <ctype.h> #include <string.h> #define MAX 100 char data[MAX][MAX], tempd...

Go to advanced search