-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathlog.txt
152 lines (90 loc) · 3.04 KB
/
log.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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
Team Incredibly Cohesive (David Chen, Jaylen Zeng, Orion Roven)
APCS pd8
L03: Get Empirical
16-12-2021
*added BinSearch and LinSearch
*read currentTimeMillis() description in library/resources
*added steps 0-6 of plan.txt
17-12-2021
*tested BinSearch and LinSearch with a dataset if length 100000000
*On average, we found that LinSearch took a significantly longer time in milliseconds to find the target
18-12-2021
* David - Refactored test to use 2d arrays
* David - Added methodology section to README
* David - Added multiple trials and average time for each test case
* David - Added conclusions and results to README
- Related to Big O and time complexity
-----------------Testing array of size 50000000-----------------
----Binary Search----
Best case: 0.001 ms
Worst case: 0.001 ms
----Linear Search----
Best case: 0.0 ms
Worst case: 10.18 ms
-----------------Testing array of size 100000000-----------------
----Binary Search----
Best case: 0.002 ms
Worst case: 0.0 ms
----Linear Search----
Best case: 0.0 ms
Worst case: 20.154 ms
-----------------Testing array of size 200000000-----------------
----Binary Search----
Best case: 0.0 ms
Worst case: 0.0 ms
----Linear Search----
Best case: 0.0 ms
Worst case: 40.928 ms
19-12-2021
* Orion - updated notes for System.currentTimeMillis
20-12-2021
* Orion - updated notes for conclusions relative to the length of the dataset
* Jaylen - updated notes further detailing Tests Performed
21-12-2021
* Orion, Jaylen - went to CS dojo, incorporated notes for gallery walkthrough
* Orion - learned about time complexity and big O notation
* A linear algorithm, that iterates through a 1-D array has time complexity O(N)
* An algorithm with a nested for loop, possibly to loop through a 2-D array, has time complexity O(N^2)
* Jaylen - updated README.md for gallery view
-----------------Testing array of length 100-----------------
----Binary Search----
Worst case: 0.002 ms
----Linear Search----
Worst case: 0.0 ms
-----------------Testing array of length 1000-----------------
----Binary Search----
Worst case: 0.001 ms
----Linear Search----
Worst case: 0.0 ms
-----------------Testing array of length 10000-----------------
----Binary Search----
Worst case: 0.0 ms
----Linear Search----
Worst case: 0.003 ms
-----------------Testing array of length 100000-----------------
----Binary Search----
Worst case: 0.0 ms
----Linear Search----
Worst case: 0.016 ms
-----------------Testing array of length 1000000-----------------
----Binary Search----
Worst case: 0.0 ms
----Linear Search----
Worst case: 0.151 ms
-----------------Testing array of length 5000000-----------------
----Binary Search----
Worst case: 0.0 ms
----Linear Search----
Worst case: 0.76 ms
-----------------Testing array of length 10000000-----------------
----Binary Search----
Worst case: 0.001 ms
----Linear Search----
Worst case: 1.797 ms
-----------------Testing array of length 25000000-----------------
----Binary Search----
Worst case: 0.0 ms
----Linear Search----
Worst case: 4.679 ms
22-12-2021
* David - update results