-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexpo.txt
81 lines (50 loc) · 1.4 KB
/
expo.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
1 2 3 4 // quadrants
q = [(1, 1),(-1, 1),(-1 ,-1),(1 ,-1)]
c = 1 2 3 4 // points
1 3 2 1 //quadrants
x = [(1, 1),(-1, -1), {(-1 ,1),(1 ,1)} ]
c = 3 4 // points
2 4 2 1 // quadrants
y = [ {(-1, 1),(1, -1),(-1 ,1)} ,(1 ,1)]
c = 1 2 3 // points
1111
1100
0201
1 1 1 1
[(1, 1),(-1, 1),(-1 ,-1),(1 ,-1)]
1 1 0 0
[(1, 1),(-1, 1),(-1 ,-1),(1 ,-1)]
0 2 0 1
[(1, 1),(-1, 1),(-1 ,-1),(1 ,-1)]
// use a hash table for the quadrants and see how many times
// the points specified apear there
1 2 3 4 // quadrants
q = [(1, 1),(-1, 1),(-1 ,-1),(1 ,-1)]
is 1 found in x 0 times
is 2 found in x 2 times
is 3 found in x 0 times
is 4 found in x 1 times
2 4 2 1 // quadrants
x = [ {(-1, 1),(1, -1),(-1 ,1)} ,(1 ,1)]
c = 1 2 3 // points
reflect
getQuadNums
getOccurance
reflect(input[i][0], +input[i][1], +input[i][2], quadrants);
[
[C 3970 8708],
[Y 4180 8536],
[Y 2599 9578],
[Y 5072 11599],
[Y 1843 6071],
[C 2237 10655],
[X 2984 8840],
[C 234 3815],
[Y 4063 4180],
[[X 1316 9151], [Y 70 11488]],
[Y 470 8605],
[[X 4873 10332],[Y 13009 13301]],
[Y 2280 6062],
[C 6763 10985],
[X 8855 13102],
]