Search found 161 matches

by ayon
Fri Nov 11, 2005 7:06 pm
Forum: Volume 100 (10000-10099)
Topic: 10078 - The Art Gallery
Replies: 20
Views: 6281

thats right mf, i also noticed that lately, i missed checking the 2nd point and got wa, after checking that point i got accepted. anyhow, the judge doesn't give such critical inputs(as tan_yui said, closed area inside the whole area). so checking cw/ccw or convex hull, both can solve the problem. th...
by ayon
Wed Nov 09, 2005 4:04 pm
Forum: Volume 100 (10000-10099)
Topic: 10078 - The Art Gallery
Replies: 20
Views: 6281

:o oops, so this is the critical case. i didnt think of it. anyway thanx to tan_Yui very much. I'll try this problem with convex hull.
by ayon
Wed Nov 09, 2005 8:35 am
Forum: Volume 100 (10000-10099)
Topic: 10078 - The Art Gallery
Replies: 20
Views: 6281

10078

i got wa's and wa's in this problem. I use the algo, if all turns are clockwise or all turns are counterclockwise, then "No", else "Yes".

Code: Select all

 cut after ac
Can anyone tell me, what's wrong, or give me some crirtical I/O ?
by ayon
Mon Nov 07, 2005 2:49 pm
Forum: Volume 100 (10000-10099)
Topic: 10099 - The Tourist Guide
Replies: 91
Views: 28873

:oops: what a fool i am !!! anyway, thanx to mf very much, i wrote my code and got accepted
by ayon
Sun Nov 06, 2005 11:12 am
Forum: Volume 100 (10000-10099)
Topic: 10099 - The Tourist Guide
Replies: 91
Views: 28873

10099

Hi,
my problem is very simple. I cannot undersatnd the sample input !!! In the sample input i think the maximin distance is 25. so for 99 tourists it takes minimum ceil(99/25) = 4 trips. then why they says Minimum Number of Trips = 5 ? :roll: plz help...
by ayon
Thu Nov 03, 2005 10:48 am
Forum: Volume 4 (400-499)
Topic: 468 - Key to Success
Replies: 33
Views: 4280

I am not sure about the line !!!
=> lower.ch=i+'A-26';

what is meant by 'A-26' ?

moreover this is a multiple input problem. you have to count how many testcases...
by ayon
Sat Oct 29, 2005 7:02 am
Forum: Off topic (General chit-chat)
Topic: Anagram
Replies: 2
Views: 1521

If you want to know that, if two words are anagram or not, just simply sort them and compare. If they are same, they are anagram. And if you want to generate all the anagrams of a given word, you can use STL next_permutation() function included in <algorithm>
by ayon
Thu Oct 27, 2005 6:42 pm
Forum: Algorithms
Topic: anagram(next_permutation)
Replies: 2
Views: 1176

Hi Bj
by ayon
Thu Oct 27, 2005 12:16 pm
Forum: Volume 5 (500-599)
Topic: 534 - Frogger
Replies: 41
Views: 17807

You can use
for(i = 0; i < n; ++i)
for(j = i; j < n; ++j)
if(i == j)
cost[j] = 0;
else
cost[j] = cost[j] = length(A.x, A.y, A[j].x, A[j].y );

and the length can be used as:
sqrt((A.x-A[j].x)*(A.x-A[j].x) + (A.y-A[j].y)* (A.y-A[j].y))
by ayon
Thu Oct 27, 2005 11:55 am
Forum: Algorithms
Topic: anagram(next_permutation)
Replies: 2
Views: 1176

anagram(next_permutation)

I tried but cannot use the STL next permutation :cry: anyone please show any example to use this?
by ayon
Thu Oct 27, 2005 10:29 am
Forum: Volume 100 (10000-10099)
Topic: 10035 - Primary Arithmetic
Replies: 328
Views: 57887

Your code is ok, but you made a spelling mistake :D
write "No carry operation.\n" instead of "No carry operations.\n" !!!

Go to advanced search