Search found 78 matches

by Sanny
Sun Jun 26, 2005 11:13 am
Forum: Volume 103 (10300-10399)
Topic: 10328 - Coin Toss
Replies: 19
Views: 7560

Yes, my previous and your current i/o all are correct. I had a mistake in my subtraction code.


Regards
Sanny
by Sanny
Sun Jun 19, 2005 11:40 am
Forum: Volume 107 (10700-10799)
Topic: 10721 - Bar Codes
Replies: 26
Views: 12139

Can you explain a bit what's the 2D approach. I've done it using a 4D array with dimensions [50][2][50][50].


Regards
Sanny
by Sanny
Thu Jun 16, 2005 10:25 pm
Forum: Volume 103 (10300-10399)
Topic: 10328 - Coin Toss
Replies: 19
Views: 7560

Got AC now. Had a mistake in my bigint.
by Sanny
Thu Jun 16, 2005 5:50 pm
Forum: Volume 108 (10800-10899)
Topic: 10815 - Andy's First Dictionary
Replies: 116
Views: 30274

10815 - Andy's First Dictionary

Problem description says that number of distinct words will be less than 5000. But you're assuming total number of words to be less than 5000.
by Sanny
Wed Jun 15, 2005 8:25 pm
Forum: Volume 103 (10300-10399)
Topic: 10328 - Coin Toss
Replies: 19
Views: 7560

My WA code gives the same output. Some more I/O - Input: 100 1 100 2 100 100 100 50 100 99 50 1 89 88 1 1 22 11 45 40 58 7 Output: 1267650600228229401496703205375 1267650599300856709303624206200 1 29273397577908224 3 1125899906842623 3 1 13312 112 55279115543405360 BTW, I'm using a slightly differen...
by Sanny
Tue Jun 14, 2005 11:08 am
Forum: Volume 101 (10100-10199)
Topic: 10111 - Find the Winning Move
Replies: 16
Views: 5036

My outputs are same as yours. Think it is time to post the code...

Code: Select all

Got AC now. Recoded it in a better way.
by Sanny
Mon Jun 13, 2005 8:23 pm
Forum: Volume 101 (10100-10199)
Topic: 10111 - Find the Winning Move
Replies: 16
Views: 5036

10111 - Find the Winning Move

Anyone can check these i/o please. I'm getting WA. Input: ? .... .xx. .oo. .... ? xoxo oxox xoxo .... ? xoxo oxox xoxo .x.o ? xx.. .... ...o ...o ? x... x... ...o ...o ? .... .xo. .ox. .... ? x.x. ooo. xxxo oox. ? o... .ox. .xxx xooo ? oxox xxoo xxox o..o ? .... .xxx .ooo .... $ Output: ##### (3,3) ...
by Sanny
Thu Jun 09, 2005 5:00 pm
Forum: ACM ICPC Archive Board
Topic: archive 3015 - Zeros and Ones
Replies: 2
Views: 1052

Got AC now. My mistake was when K=0. Thanks.
by Sanny
Wed Jun 08, 2005 5:04 pm
Forum: ACM ICPC Archive Board
Topic: archive 3015 - Zeros and Ones
Replies: 2
Views: 1052

archive 3015 - Zeros and Ones

Anybody can check this i/o please. I'm getting WA :( Input: 15 1 0 63 100 64 1 64 0 53 53 54 54 50 99 10 100 25 25 64 100 6 3 6 4 6 2 26 3 64 2 Output: Case 1: 0 Case 2: 0 Case 3: 916312070471295267 Case 4: 916312070471295267 Case 5: 0 Case 6: 18358397026615 Case 7: 637606458151 Case 8: 0 Case 9: 0 ...
by Sanny
Mon May 30, 2005 11:58 pm
Forum: Algorithms
Topic: Polygon Intersection
Replies: 4
Views: 1255

Thanks to misof for that very nice link.

Regards
Sanny
by Sanny
Mon May 30, 2005 9:30 pm
Forum: Volume 6 (600-699)
Topic: 618 - Doing Windows
Replies: 4
Views: 3743

618 - Doing Windows WA

I'm trying to solve this problem by placing the windows in 4! positions. In each position I solve four linear equations like: w[1] * a + w[2] * b = ws w[3] * c + w[4] *d = ws h[1] * a + h[4] * d = hs h[2] * b + h[3] * c = hs If these equations give reasonable values for a,b,c,d ( which are the expan...
by Sanny
Sun May 29, 2005 4:09 pm
Forum: Algorithms
Topic: Polygon Intersection
Replies: 4
Views: 1255

Yes
by Sanny
Sun May 29, 2005 8:55 am
Forum: Algorithms
Topic: Polygon Intersection
Replies: 4
Views: 1255

Polygon Intersection

How can I find the total area covered by some polygons ( Not just axis parallel polygons) ? Any help will be greatly appreciated.

Regards
Sanny
by Sanny
Thu May 26, 2005 1:12 pm
Forum: Volume 6 (600-699)
Topic: 694 - The Collatz Sequence
Replies: 46
Views: 15747

Use memoization.

Regards
Sanny
by Sanny
Sun May 22, 2005 2:24 pm
Forum: Algorithms
Topic: Lines and a point
Replies: 4
Views: 984

I think it can be done in the following way: 1. First convert all the points into polar co-ordinate system taking the given point as origin. 2. Sort all the points by their angles. 3. Now between two consecutive points, draw a big enough line segment from the origin and determine which line it inter...

Go to advanced search