1206 - Boundary Points

All about problems in Volume 12. If there is a thread about your problem, please use it. If not, create one with its number in the subject.

Moderator: Board moderators

Post Reply
red_apricot
New poster
Posts: 48
Joined: Sun Jun 22, 2014 6:14 am

Re: 1206 - Boundary Points

Post by red_apricot » Thu Nov 20, 2014 9:59 am

The problem's name is "Boundary Points", so initially I thought we have to print the points lying on edges as well, not only on corners. OK, now it is clear that this problem is clear-cut convex hull. However, I'm getting WA. My question is: if, for instance, the point is given as (-3.24324,4.4) we should output it exactly like that? That means storing string constants alongside the points themselves?

brianfry713
Guru
Posts: 5947
Joined: Thu Sep 01, 2011 9:09 am
Location: San Jose, CA, USA

Re: 1206 - Boundary Points

Post by brianfry713 » Thu Nov 20, 2014 9:39 pm

You can read them as doubles and use printf("%g")
Check input and AC output for thousands of problems on uDebug!

red_apricot
New poster
Posts: 48
Joined: Sun Jun 22, 2014 6:14 am

Re: 1206 - Boundary Points

Post by red_apricot » Fri Nov 21, 2014 4:31 am

Thanks Brian. Got AC now. Yes, this is a clear-cut Convex Hull problem with small n, but with very good input.

Post Reply

Return to “Volume 12 (1200-1299)”