Search found 5 matches

by Vartanov Daniel
Thu Nov 07, 2002 7:42 am
Forum: Volume 103 (10300-10399)
Topic: 10374 - Election
Replies: 44
Views: 15768

Hmm, i think, i shouldn't have problems with scanf\gets, looak at this: [cpp] #include <stdio.h> #include <string.h> #include <stdlib.h> int n, m; int partynum; struct Tparty { char name[80]; int votes; int independ; } parties[20]; struct Tcand { char name[80]; char party[80]; int votes; } cand[20];...
by Vartanov Daniel
Wed Nov 06, 2002 3:04 pm
Forum: Volume 103 (10300-10399)
Topic: 10374 - Election
Replies: 44
Views: 15768

10374 - Election

I really don't know, where I have mistake. Can anyone write some tests?
May be there are some situations, in case of wich my program works wrong.
by Vartanov Daniel
Wed Aug 28, 2002 8:00 pm
Forum: Volume 100 (10000-10099)
Topic: 10055 - Hashmat the Brave Warrior
Replies: 166
Views: 49484

Thanks a lot... it was my fault, may be because of bad English :))))
by Vartanov Daniel
Wed Aug 28, 2002 11:02 am
Forum: Volume 100 (10000-10099)
Topic: 10055 - Hashmat the Brave Warrior
Replies: 166
Views: 49484

10055 - Hashmat the brave warrior; What's the trick here?

I really didn't understand, how to get WA for this problem, and i understood it after i posted my solution. Is there some tricks in this problem? #include <stdio.h> int main() { unsigned long hashmat, versa; while (scanf("%ld %ld", &hashmat, &versa) == 2) printf("%ld\n", versa - hashmat); return 0; ...
by Vartanov Daniel
Tue Aug 27, 2002 8:16 pm
Forum: Volume 1 (100-199)
Topic: 100 - The 3n + 1 problem
Replies: 1394
Views: 202211

100 - 3n+1 Problem (SIGSEGV!!!! It can't be!)

6 monthes ago i got AC for this problem!!! I posted this problem again several hours ago and got SIGSEGV, but i DID NOT change my code!!! #include <stdio.h> #include <string.h> long sol[10001]; void precount() { long t; long c; for (long i = 1; i <= 10000; i++) { c = 0; t = i; while (t != 1) { if (t...

Go to advanced search