Commit Graph

13 Commits

Author SHA1 Message Date
Yudong Jin 881d573790 Refactor the articles related to searching algorithm. Add the chapter of binary search. Add the section of searching algorithm revisited. (#464) 2023-04-17 18:22:18 +08:00
Gonglja 8bc41bc013 Add space_complexit under C and fix memory leak under CPP (#456)
* fix(codes/cpp): Memory leak fix: the space was not freed when pop removed the element.

* fix(codes/cpp): Fix access error when printArray(arr, 0)

* fix(codes/cpp): Fix memory leaks: replace pointers with local variables, no need to manage memory

* fix(codes/cpp): Fix memory leaks: no delete

* fix(codes/cpp): Fix memory leaks: Add destructor ~ArrayHashMap()

* Update PrintUtil.hpp

* feat(codes/c): Add three-party hash implementation

* feat(codes/c): Add freeMemoryTree in tree_node.h

* feat(codes/c): Add space_complexity.c

* styles(codes/c): Modify format

* feat(codes/cpp): Undo a previous delete, there is no memory leak here

* Update array_hash_map.cpp

* Update include.h

---------

Co-authored-by: Yudong Jin <krahets@163.com>
2023-04-15 23:51:35 +08:00
Yudong Jin 70dead5cd0 Update worst_best_time_complexity,
leetcode_two_sum
2023-02-03 18:53:15 +08:00
Reanon da405b579d Modify the code style of C (#299)
* style(my_list): modify c codes.

* style(stack): modify c codes.

* style(hash): modify c codes.
2023-01-29 00:08:12 +08:00
Yudong Jin 40b5be5302 Unify the naming of the C codes. 2023-01-12 00:31:11 +08:00
Yudong Jin 6a46e38e1b Merge pull request #228 from sjinzh/master
add zig codes for Section 'Space Complexity' and 'Space Time Tradeoff'
2023-01-11 14:32:59 +08:00
reanon 24cdcd54df feat(codes/c): add C include/ codes and modify exist C codes 2023-01-11 00:55:21 +08:00
sjinzh a667e71b20 fix bug 2023-01-10 19:29:57 +08:00
Yudong Jin 73e3452838 Add Swift language blocks to the docs. 2023-01-08 19:41:05 +08:00
Yudong Jin 0e49f0053a Update the format of the file headers
of c, cpp, java, js, ts, swift.
2023-01-06 03:39:19 +08:00
sjinzh ea867eadac (PR #204) update c code and doc for time_complexity 2023-01-05 08:39:09 +08:00
sjinzh 9e4a5fd6d8 update c code for chapter_computational_complexity, add c code to time_complexity.md 2023-01-04 08:09:22 +08:00
sjinzh 1b356ba0a2 add c code for chapter_computational_complexity 2023-01-03 21:19:11 +08:00