Search found 5 matches

by george3456
Sat Oct 31, 2009 5:48 pm
Forum: Volume 106 (10600-10699)
Topic: 10664 - Luggage
Replies: 20
Views: 14210

Re: 10664 - Luggage

This piece of code is accepted..... but I am sure it shows wrong output for this input: 3 3 3 3 2 2 2 2 2 2 2 2 2 output should be: YES but this code shows : NO and however ACCEPTED. WHY??? #include<stdio.h> #include<stdlib.h> int comp(void const * a, void const * b) { return ( *(int*) b - *(int*)a)...
by george3456
Sat Oct 31, 2009 12:36 am
Forum: Volume 6 (600-699)
Topic: 612 - DNA Sorting
Replies: 122
Views: 17612

Re: 612 - DNA Sorting without SORTING

One of my solution is accepted. But it is taking almost 2.4s which is longer. So I tried to reduce the time. In the following approach I tried not to use any sorting....... but this code is getting RTE. do you have any idea??? #include<stdio.h> #include<string.h> int main() { int tcase; scanf("%d",&...
by george3456
Sat Oct 24, 2009 3:05 pm
Forum: Volume 100 (10000-10099)
Topic: 10038 - Jolly Jumpers
Replies: 445
Views: 85747

Re: 10038 - Jolly Jumpers

Help plzzzz ... do you have any idea why this code is getting CE??

code removed after acc
OKK sorted it out
i thought

Code: Select all

 int abs( int x) 
is in the header <math.h>
infact it is in <stdlib.h> header
by george3456
Fri Oct 23, 2009 1:01 am
Forum: Volume 4 (400-499)
Topic: 492 - Pig-Latin
Replies: 213
Views: 27809

Why RTE >> Piglatin 492

don't know why getting RTE..... help plzzzzzzzzzzz #include<stdio.h> #include<string.h> #include<ctype.h> int main() { char s[300000],t[300000]; char temp; //freopen("in.txt","r",stdin); //freopen("out.txt","w",stdout); while(gets(s)) { long i,len; len = strlen(s); //printf("%d",len); for(i = 0;i<le...
by george3456
Mon Oct 19, 2009 11:54 am
Forum: Volume 112 (11200-11299)
Topic: 11223 - O: dah dah dah!
Replies: 43
Views: 19288

Re: 11223 - O: dah dah dah!

check your '\n' line printing... :-?

Go to advanced search