805 - Polygon Intersections

All about problems in Volume 8. 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
brianfry713
Guru
Posts: 5947
Joined: Thu Sep 01, 2011 9:09 am
Location: San Jose, CA, USA

805 - Polygon Intersections

Post by brianfry713 » Wed Aug 27, 2014 8:17 pm

I/O by morris821028

Code: Select all

9 -2 0 -3 1 -2 3 0 4 -2 2 -1 2 1 4 2 4 2 0
4 -3 2 3 2 3 0 -3 0
 
9 -2 0 -3 1 -2 3 0 4 -2 2 -1 2 1 4 2 4 2 0
4 -3 4 3 4 3 0 -3 0
 
9 -2 0 -3 1 -2 3 0 4 -2 2 -1 2 1 4 2 4 2 0
4 -3 3 3 3 3 2 -3 2
 
4 -2 2 -2 1 -1 1 -1 2
4 -1 3 0 2 0 3 -1 2
 
6 -3 2 -1 0 1 0 3 2 1 4 -1 4
6 -1 1 1 1 3 -1 1 -3 -1 -3 -3 -1
 
8 -2 3 -1 0 1 0 2 3 3 -1 1 -2 -1 -2 -3 -1
4 -2 3 -1 0 1 0 2 3
 
8 -3 2 -1 0 1 0 3 2 3 -1 1 -2 -1 -2 -3 -1
4 -3 2 -2 1 2 1 3 2
 
5 -3 -2 -3 2 0 0 3 2 3 -2
4 -2 1 2 1 2 -1 -2 -1
 
4 0 0 0 1 1 1 1 0
4 0 0 0 1 1 1 1 0
 
4 0 0 2 0 2 2 0 2
4 -1 3 2 3 2 -1 -1 -1
 
4 0 0 0 1 1 1 1 0
4 0 0 1 1 2 0 1 -1
 
4 0 0 1 0 1 1 0 1
4 0 0 0 1 -1 1 -1 0
 
3 2 1 8 5 0.5 3.5
5 1.5 3 2 7 6.5 6.5 6.5 3.25 4 4.5
 
10 -2 0 -2 3 0 2 1 3 1 1 2 3 3 0 1 -2 0 0 -1 -1
5 -3 1 4 2 -1 0 2 -1 -1 -2
 
4 0 0 1 0 1 1 0 1
4 -1 -1 2 -1 2 2 -1 2
 
0
0 

Code: Select all

Data Set 1
Number of intersection regions: 1
Region 1:(-3.00,1.00)(-2.50,2.00)(2.00,2.00)(2.00,0.00)(-2.00,0.00)
Data Set 2
Number of intersection regions: 1
Region 1:(-3.00,1.00)(-2.00,3.00)(0.00,4.00)(-2.00,2.00)(-1.00,2.00)(1.00,4.00)(2.00,4.00)(2.00,0.00)(-2.00,0.00)
Data Set 3
Number of intersection regions: 2
Region 1:(-2.50,2.00)(-2.00,3.00)(-1.00,3.00)(-2.00,2.00)
Region 2:(-1.00,2.00)(0.00,3.00)(2.00,3.00)(2.00,2.00)
Data Set 4
Number of intersection regions: 0
Data Set 5
Number of intersection regions: 1
Region 1:(-1.50,0.50)(-1.00,1.00)(1.00,1.00)(1.50,0.50)(1.00,0.00)(-1.00,0.00)
Data Set 6
Number of intersection regions: 0
Data Set 7
Number of intersection regions: 0
Data Set 8
Number of intersection regions: 1
Region 1:(-2.00,-1.00)(-2.00,1.00)(-1.50,1.00)(0.00,0.00)(1.50,1.00)(2.00,1.00)(2.00,-1.00)
Data Set 9
Number of intersection regions: 1
Region 1:(0.00,0.00)(0.00,1.00)(1.00,1.00)(1.00,0.00)
Data Set 10
Number of intersection regions: 1
Region 1:(0.00,0.00)(0.00,2.00)(2.00,2.00)(2.00,0.00)
Data Set 11
Number of intersection regions: 1
Region 1:(0.00,0.00)(1.00,1.00)(1.00,0.00)
Data Set 12
Number of intersection regions: 0
Data Set 13
Number of intersection regions: 2
Region 1:(1.50,3.00)(1.59,3.72)(3.25,4.05)
Region 2:(4.43,4.29)(6.50,4.70)(6.50,4.00)(5.86,3.57)
Data Set 14
Number of intersection regions: 2
Region 1:(-2.00,0.00)(-2.00,1.14)(1.00,1.57)(1.00,1.00)(1.31,1.62)(2.41,1.77)(2.53,1.41)(-1.00,0.00)(-0.25,-0.25)(-1.00,-1.00)
Region 2:(0.20,-0.40)(2.00,-1.00)(0.71,-1.43)
Data Set 15
Number of intersection regions: 1
Region 1:(0.00,0.00)(0.00,1.00)(1.00,1.00)(1.00,0.00)
Check input and AC output for thousands of problems on uDebug!

Post Reply

Return to “Volume 8 (800-899)”