Skip to content

Commit 002b046

Browse files
Merge pull request #7 from GChristensson/doc/#1
doc/#1: Answered questions to the part about complexity
2 parents c6d62bb + 2cae18e commit 002b046

File tree

1 file changed

+36
-6
lines changed

1 file changed

+36
-6
lines changed

README.md

Lines changed: 36 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -76,12 +76,42 @@ for each project, along with reason(s) why you changed to a different one.
7676
## Complexity
7777

7878
1. What are your results for ten complex functions?
79-
* Did all methods (tools vs. manual count) get the same result?
80-
* Are the results clear?
81-
2. Are the functions just complex, or also long?
82-
3. What is the purpose of the functions?
83-
4. Are exceptions taken into account in the given measurements?
84-
5. Is the documentation clear w.r.t. all the possible outcomes?
79+
* 1: _remove_repair (lines 212-283) (CCN: 31)
80+
* 2: canny (lines 21-113) (CCN: 26)
81+
* 3: points_to_polynomial (lines 1-103) (CCN: 21)
82+
* 4: next_term (lines 21-107) (CCN: 20)
83+
* 5: solution (lines 95-149) (CCN: 20)
84+
* 6: bidirectional_dij (lines 20-107) (CCN: 20)
85+
* 7: search (lines 12-74) (CCN: 20)
86+
* 8: inverse_of_matrix (lines 8-155) (CCN: 20)
87+
* 9: move (lines 155-210) (CCN: 19)
88+
* 10: find_optimal_binary_search_tree (lines 68-134) (CCN: 19)
89+
90+
**Q: Did all methods (tools vs. manual count) get the same result?**
91+
92+
**A:** We chose to manually count 5 functions as follows:
93+
94+
* Canny: Same results
95+
* Optimal binary search tree: Same results
96+
* Search: Not the same results. Lizard got 20 and we counted 21.
97+
* Inverse of matrix: Not the same results. Lizard got 20 while we got differing results. We eventually counted it manually together as a whole group but could still not get the same result as lizard.
98+
* Bidirectional dijkstra's: Same as with the case of the "Inverse of matrix" above.
99+
100+
**Q: Are the functions just complex, or also long?**
101+
102+
**A:** Some functions are "long" (around 100 lines) while some are shorter (around 50 lines). The functions did not seem too complex, in the sense of having nested loops, etc.
103+
104+
**Q: What is the purpose of the functions?**
105+
106+
**A:** The purpose of the functions are to implement different kinds of algorithms. The names of the functions are self-explanatory and thus explains the purpose of the functions well.
107+
108+
**Q: Are exceptions taken into account in the given measurements?**
109+
110+
**A:** We took exceptions into account when counting manually.
111+
112+
**Q: Is the documentation clear w.r.t. all the possible outcomes?**
113+
114+
**A:** Not quite. In most functions it is not documented why an error was raised, for example. Also, there is mostly no documentation to if-statements that explains why a certain path is taken or not.
85115

86116
## Refactoring
87117

0 commit comments

Comments
 (0)