Search found 10 matches

by vadiu
Tue Sep 28, 2004 7:16 pm
Forum: Volume 2 (200-299)
Topic: 299 - Train Swapping
Replies: 81
Views: 23946

I changed my code, now it can handle all the inputs (I think). But now it gives me WA. I may be doing something wrong. Any help would be greatly appreciated. Thanks

[c]
#include "stdio.h"
#include "string.h"

int main()
{
int N, L, matrix[51], i, a, b, count;

scanf("%d", &N);

for(i=0; i<N; i ...
by vadiu
Mon Sep 27, 2004 11:12 pm
Forum: Volume 2 (200-299)
Topic: 299 - Train Swapping
Replies: 81
Views: 23946

299 WA

I can't understand why this doesn't give me AC. Is there someone who can help me solving this problem? Thanks...

[c]
#include "stdio.h"
#include "string.h"

int main()
{
int N, L, matrix[51], i, a, b, count;

scanf("%d", &N);

for(i=0; i<N; i++)
{

count=0;
b=0;
scanf("%d", &L);

for(a=0; a ...
by vadiu
Fri Sep 17, 2004 6:09 pm
Forum: Volume 1 (100-199)
Topic: 102 - Ecological Bin Packing
Replies: 485
Views: 116158

102 - Ecological Bin Packing

I can't understand why my code gives me WA. This problem is easy, and I've read all the posts. :( I would be greatful if someone could help me.
[c]
#include "stdio.h"
#include "string.h"


int main()
{
int i;
char order[5];
unsigned long int matrix[9], sum=0;

while(!feof(stdin))
{
for(i=0; i ...
by vadiu
Tue Sep 14, 2004 7:15 pm
Forum: Volume 1 (100-199)
Topic: 119 - Greedy Gift Givers
Replies: 145
Views: 47179

119 - Greedy Gift Givers

I have read all the posts about this problem and tried all the "strange\special" cases and my program gives me good results. But when i submit it he gives me Wrong Answers. I can't understand why. :-? Any help would be greatly appreciated. Thanks...

[c]
#include "stdio.h"
#include "string.h"

void ...
by vadiu
Tue Jul 27, 2004 9:42 am
Forum: Volume 5 (500-599)
Topic: 591 - Box of Bricks
Replies: 80
Views: 24854

Thanks a lot. I got AC. :D
by vadiu
Mon Jul 26, 2004 8:38 pm
Forum: Volume 5 (500-599)
Topic: 591 - Box of Bricks
Replies: 80
Views: 24854

591 - Box of Bricks

This problem seems to be easy but i don't really know why I get WA when I submit it. I have read all the posts about this problem, but I can't still understand what's wrong in this code. Can someone help me?

[c]#include "stdio.h"


int x, i, heights[51], z, number=1, media, moves=0;

int calc ...
by vadiu
Wed Jul 21, 2004 4:25 pm
Forum: Volume 100 (10000-10099)
Topic: 10018 - Reverse and Add
Replies: 169
Views: 43709

i removed the " if(a==o) return 0 " in the IsPalindrome() function and then the program just print 0 and the number if it (the number) is a palindrome. then i submit it and now it gives a runtime error. "File size limit exceeded". I can't understand why. Can someone help me? Thanks
by vadiu
Wed Jul 21, 2004 1:54 pm
Forum: Volume 100 (10000-10099)
Topic: 10018 - Reverse and Add
Replies: 169
Views: 43709

10018 - Reverse and Add

I've read all the topics about this problem and my program gives correct answers, i think. But when I submit the program, it gives a Time Limit Exceeded Error. Can anyone explain me why?


#include "stdio.h"
#include "stdlib.h"
#include "string.h"

int IsPalindrome();
void reverse();

char number ...
by vadiu
Tue Jul 20, 2004 3:19 pm
Forum: Volume 3 (300-399)
Topic: 382 - Perfection
Replies: 95
Views: 35245

Thank you very much. :lol:
by vadiu
Mon Jul 19, 2004 6:44 pm
Forum: Volume 3 (300-399)
Topic: 382 - Perfection
Replies: 95
Views: 35245

382 - WA

This program does everything well when I run it in my computer but wen I submit it it gives a wrong answer. Does anyone can explain me why?

[c]
#include "stdio.h"
#include "string.h"
#include "stdlib.h"

int check(int bah);
void organizer();

char list[300];
int numbers[100], a=0, g;

int main(int ...

Go to advanced search