Search found 34 matches

by wolf
Mon Dec 04, 2006 12:32 pm
Forum: Algorithms
Topic: swaping items algo problem
Replies: 5
Views: 2134

swaping items algo problem

Hi all. I have a problem like this: There is a collection of some objects and an array of integers (the same size as collection size). The objects in the collection have to be sorted in order given in the array of integers, but and it has to be assumed that the only operation allowed on the collecti...
by wolf
Sat Oct 30, 2004 2:23 pm
Forum: Volume 101 (10100-10199)
Topic: 10104 - Euclid Problem
Replies: 29
Views: 9776

Thanx a lot Noim ! I got AC now. It was a month ago I posted this code, I thought nobody reply, and now ... Thx again :-D
by wolf
Wed Oct 13, 2004 4:40 pm
Forum: Volume 1 (100-199)
Topic: 102 - Ecological Bin Packing
Replies: 485
Views: 33032

Hi ! I can't seenothing wrong in your answers (they're the same like my AC program produce), but the reason of your WA can be in sending code especialy if you send it via e-mail (sometimes this can make problems). You also have to check if you are using the proper data type in your code. Keep trying...
by wolf
Thu Sep 30, 2004 4:08 pm
Forum: Other words
Topic: What's wrong with my stats ?
Replies: 14
Views: 3593

Oh ! I see everything is correct now, however it was frustrating a little bit :-D
by wolf
Thu Sep 30, 2004 12:52 pm
Forum: Other words
Topic: What's wrong with my stats ?
Replies: 14
Views: 3593

What's wrong with my stats ?

Hey everybody ! I'm a little confused about my stats, I had 130 solved problems few day ago, but today my stats speaks - "No problems solved" !!!!!!!!! I also looked at my friends stats and he also have 13 instead of 73 !!!!!!!! What 's this ? Maybe this is some error or something ? Please, answer m...
by wolf
Fri Sep 24, 2004 10:35 pm
Forum: Off topic (General chit-chat)
Topic: How old are you? Statistics.
Replies: 121
Views: 174846

Hi ! I'm 19. I've registered 2 months ago, but I started solving 1 month ago. I solved 129 problems.
by wolf
Tue Sep 14, 2004 12:27 am
Forum: Volume 1 (100-199)
Topic: 108 - Maximum Sum
Replies: 233
Views: 21811

Hi mishu! U can try that : After reading the input data,process throught all possible combinations, but don't count the whole sum all the time. You can add a column/row of integers to existing matrix. Also you can substract the integers at the same way (if needed, I don't remember 108 well). I did i...
by wolf
Tue Sep 14, 2004 12:13 am
Forum: Volume 1 (100-199)
Topic: 100 - The 3n + 1 problem
Replies: 1394
Views: 178997

Hi woni !

First You should change all 'int' in you code to 'unsigned long' (why? see problem specification).
And second thing, you have to exchange input integers if the first integer is greater than second one (see problem specification too :-D)

Thats all I think.
by wolf
Mon Sep 13, 2004 12:14 am
Forum: Volume 4 (400-499)
Topic: 498 - Polly the Polynomial
Replies: 73
Views: 13296

Thanx a lot ! Now it's clear for me :-D
by wolf
Mon Sep 13, 2004 12:10 am
Forum: Volume 101 (10100-10199)
Topic: 10104 - Euclid Problem
Replies: 29
Views: 9776

10104 - "Euclid problem" WA

What's wrong with my simple code. It works for any input I have.

[cpp]
//AC
[/cpp]

Please, help me somebody...
by wolf
Sun Sep 12, 2004 8:29 pm
Forum: Volume 4 (400-499)
Topic: 498 - Polly the Polynomial
Replies: 73
Views: 13296

Thanx Dominik ! I never used sscanf() before, so it was easy for me to make this stupid mistake... :oops: Now I know how can I solve this problem in different way, but You mentioned about the strtok() function. Could you explain me how can I use it in above sample code, I don't know anything about t...
by wolf
Sun Sep 12, 2004 4:05 pm
Forum: Volume 4 (400-499)
Topic: 498 - Polly the Polynomial
Replies: 73
Views: 13296

sscanf using

Hi ! I've a little problem with that code ( fragment of my ACM-498 code): [cpp] #include <stdio.h> char cline[1000],xline[1000]; int i,j,a,c[100],x[100]; int main() { for (;;) { if (gets(cline)==NULL) break; gets(xline); for (i=0;;i++) { if (sscanf(cline,"%d",&c )==EOF) break; } for (j=0;;j++) { if ...
by wolf
Thu Sep 09, 2004 6:24 pm
Forum: Volume 3 (300-399)
Topic: 362 - 18,000 Seconds Remaining
Replies: 75
Views: 25756

Can anybody check my code too (I have right answers for every input I find in all the posts in this forum): [cpp] #include <iostream> #include <math.h> using namespace std; long long set,csuma,tsuma,tbytes,rbytes[5],i,secleft,k; double bitrate; void czytaj() { cout << "Output for data set " << set <...
by wolf
Mon Sep 06, 2004 2:45 pm
Forum: Volume 100 (10000-10099)
Topic: 10011 - Where Can You Hide?
Replies: 58
Views: 12447

In the problem description: "numbers less than 1 have to be printed without 0 " i.e.: .001 (not 0.001)
by wolf
Mon Sep 06, 2004 12:24 pm
Forum: Volume 100 (10000-10099)
Topic: 10010 - Where's Waldorf?
Replies: 42
Views: 17728

try "ggi" for the sample input. it displays nothing :-)

Go to advanced search