Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/douchuan/algorithm
/ functions
Functions
655 in github.com/douchuan/algorithm
⨍
Functions
655
◇
Types & classes
86
↓ 1 callers
Method
delete_dth
( &mut self, x: Option<NonNull<Node<T>>>, key: &str, d: usize, )
src/strings/tries.rs:163
↓ 1 callers
Method
delete_max
(&mut self)
src/tree/binary/rb2.rs:149
↓ 1 callers
Method
delete_min
(&mut self)
src/tree/binary/rb2.rs:136
↓ 1 callers
Method
dfs
(&mut self, g: &dyn IGraph, v: usize)
src/graph/undirected/cc.rs:70
↓ 1 callers
Method
dfs
(&mut self, g: &dyn IGraph, v: usize, u: usize)
src/graph/undirected/cycle.rs:47
↓ 1 callers
Method
dfs
(&mut self, g: &dyn IGraph, v: usize)
src/graph/undirected/bipartite.rs:61
↓ 1 callers
Method
dfs
(&mut self, g: &dyn IGraph, v: usize)
src/graph/undirected/dfs.rs:47
↓ 1 callers
Method
dfs
(&mut self, graph: &dyn IGraph, v: usize)
src/graph/directed/scc.rs:50
↓ 1 callers
Method
dfs
(&mut self, g: &dyn IGraph, v: usize)
src/graph/util/paths.rs:96
↓ 1 callers
Method
dist_to
(&self, i: usize)
src/graph/shortest/cpm.rs:43
↓ 1 callers
Function
do_check
(items: &[char])
src/strings/palindrome.rs:6
↓ 1 callers
Function
do_drop
(head: Option<NonNull<Node<T>>>)
src/ll/linked_list.rs:184
↓ 1 callers
Function
do_find
设链表的长度为 N。设置两个指针 P1 和 P2,先让 P1 移动 K 个节点, 则还有 N - K 个节点可以移动。此时让 P1 和 P2 同时移动,可以知道 当 P1 移动到链表结尾时,P2 移动到第 N - K 个节点处,该位置就是 倒数第 K 个节点。
src/ll/kth2tail.rs:17
↓ 1 callers
Function
do_reverse
递归,先找到tail,然后从后向前修正指针
src/ll/reverse.rs:9
↓ 1 callers
Method
dot
Returns the inner product of this vector with the specified vector.
src/math/sparse_vector.rs:52
↓ 1 callers
Function
expand_sharp
"#" symbol as empty child
src/tree/binary/builder/level.rs:65
↓ 1 callers
Method
find_negative_cycle
by finding a cycle in predecessor graph
src/graph/shortest/bellman_ford_sp.rs:77
↓ 1 callers
Method
flip
(&self)
src/tree/binary/node.rs:298
↓ 1 callers
Method
get
Returns the value associated with the given key.
src/strings/tries.rs:80
↓ 1 callers
Method
has_parallel_edges
does this graph have two parallel edges?
src/graph/undirected/cycle.rs:73
↓ 1 callers
Method
has_path_to
Returns true if there is a path from the source vertex s to vertex v
src/graph/shortest/dijkstra_sp.rs:69
↓ 1 callers
Function
height
(node: Option<NonNull<Node<K, V>>>)
src/tree/binary/tree.rs:49
↓ 1 callers
Method
height
(&self)
src/tree/binary/tree.rs:10
↓ 1 callers
Method
i_am_right
(&self)
src/tree/binary/node.rs:235
↓ 1 callers
Method
id
(&self, v: usize)
src/graph/directed/scc.rs:40
↓ 1 callers
Function
insert
Ok(inserted node) Err(()): element exists # Safety This is highly unsafe, due to pointer
src/tree/binary/bst.rs:69
↓ 1 callers
Method
insert
(&mut self, key: K, val: V)
src/tree/binary/rb.rs:136
↓ 1 callers
Function
insert_fix
( root: Option<NonNull<Node<K, V>>>, x: Option<NonNull<Node<K, V>>>, )
src/tree/binary/rb.rs:155
↓ 1 callers
Method
is_branch
(&self)
src/tree/binary/node.rs:244
↓ 1 callers
Method
is_leaf
(&self)
src/tree/binary/node.rs:239
↓ 1 callers
Function
is_less
is v less than w, starting at d-th character
src/sort/insert.rs:40
↓ 1 callers
Function
keys
add the keys between lo and hi in the subtree rooted at x to the queue
src/tree/binary/bst.rs:286
↓ 1 callers
Method
keys_with_prefix
Returns all of the keys in the set that start with *prefix
src/strings/tries.rs:111
↓ 1 callers
Function
longest_prefix_of_dth
returns the length of the longest string key in the subtrie rooted at x that is a prefix of the query string, assuming the first d character match and
src/strings/tries.rs:259
↓ 1 callers
Function
make_change_classic
暴力穷举
src/dp/coin.rs:26
↓ 1 callers
Function
make_change_iter
(coins: &[i32], amount: i32)
src/dp/coin.rs:52
↓ 1 callers
Method
mark
(&mut self, graph: &dyn IGraph, s: usize)
src/graph/undirected/dfs2.rs:30
↓ 1 callers
Method
marked
is v reachable?
src/graph/directed/search.rs:31
↓ 1 callers
Method
max
(&self)
src/tree/binary/rb2.rs:183
↓ 1 callers
Method
min
(&self)
src/tree/binary/bst.rs:46
↓ 1 callers
Method
min
(&self)
src/tree/binary/rb2.rs:179
↓ 1 callers
Method
negative_cycle
Returns a negative cycle reachable from the source vertex s, or None if there is no such cycle.
src/graph/shortest/bellman_ford_sp.rs:100
↓ 1 callers
Method
opportunity_cycle
(&self)
src/graph/shortest/arbitrage.rs:34
↓ 1 callers
Function
parse_list_num
用空格分割的两个数字 "1 2"
src/graph/util/parser.rs:95
↓ 1 callers
Function
parse_list_rates
USD 1 0.741 0.657 1.061 1.005
src/graph/util/parser.rs:115
↓ 1 callers
Method
partial_cmp
(&self, other: &Self)
src/graph/shortest/directed_edge.rs:32
↓ 1 callers
Method
path_to
Returns a shortest path from the source vertex s to vertex v
src/graph/shortest/dijkstra_sp.rs:74
↓ 1 callers
Method
peek
Returns (but does not remove) the item most recently added to this stack.
src/common/stack.rs:22
↓ 1 callers
Function
pop
(tree: &mut Tree<K, V>)
src/tree/binary/builder/tournament.rs:36
↓ 1 callers
Method
post
Returns the vertices in postorder
src/graph/directed/order.rs:27
↓ 1 callers
Method
pre
Returns the vertices in preorder.
src/graph/directed/order.rs:22
↓ 1 callers
Function
pred
# Safety This is highly unsafe, due to pointer
src/tree/binary/bst.rs:175
↓ 1 callers
Method
prim
run Prim's algorithm in graph G, starting from vertex s
src/graph/mst/prim_mst.rs:56
↓ 1 callers
Method
prim
(&mut self, g: &dyn IEWGraph, s: usize)
src/graph/mst/lazy_prim_mst.rs:45
↓ 1 callers
Function
put
insert the element in the subtree rooted at h
src/tree/binary/rb2.rs:201
↓ 1 callers
Function
put_dth
( x: Option<NonNull<Node<T>>>, key: &str, val: Option<T>, d: usize, )
src/strings/tst.rs:140
↓ 1 callers
Method
put_dth
( &mut self, x: Option<NonNull<Node<T>>>, key: &str, val: Option<T>, d
src/strings/tries.rs:140
↓ 1 callers
Method
relax
relax edge e and update pq if changed
src/graph/shortest/dijkstra_sp.rs:49
↓ 1 callers
Method
relax
relax vertex v and put other endpoints on queue if changed
src/graph/shortest/bellman_ford_sp.rs:51
↓ 1 callers
Function
replace_max_by_min
返回叶子节点的序号
src/tree/binary/builder/tournament.rs:55
↓ 1 callers
Method
rev_post
Returns the vertices in reverse postorder.
src/graph/directed/order.rs:32
↓ 1 callers
Method
scale
Returns the scalar-vector product of this vector with the specified scalar.
src/math/sparse_vector.rs:81
↓ 1 callers
Method
scan
(&mut self, g: &dyn IEWGraph, v: usize)
src/graph/mst/prim_mst.rs:64
↓ 1 callers
Method
search
Returns the index of the first occurrence of the pattern string in the text string.
src/strings/kmp.rs:35
↓ 1 callers
Function
search1
(pat: &str, txt: &str)
src/strings/brute_force.rs:5
↓ 1 callers
Method
set_left
(&mut self, x: Option<NonNull<Node<T>>>)
src/strings/tst.rs:277
↓ 1 callers
Method
set_mid
(&mut self, x: Option<NonNull<Node<T>>>)
src/strings/tst.rs:281
↓ 1 callers
Method
set_right
(&mut self, x: Option<NonNull<Node<T>>>)
src/strings/tst.rs:285
↓ 1 callers
Function
setup_new_max
(node: NonNull<Node<K, V>>)
src/tree/binary/builder/tournament.rs:75
↓ 1 callers
Method
step
(self)
src/graph/util/parser.rs:128
↓ 1 callers
Function
succ
# Safety This is highly unsafe, due to pointer
src/tree/binary/bst.rs:146
↓ 1 callers
Method
to_char
Returns the character corresponding to the argument index
src/strings/alphabet.rs:111
Function
Bellman_Ford_sp
()
tests/test_shortest_paths.rs:167
Function
Dijkstra_all_pairs_sp
()
tests/test_shortest_paths.rs:81
Function
Dijkstra_sp
()
tests/test_shortest_paths.rs:55
Method
E
(&self)
src/graph/directed/digraph.rs:17
Method
E
(&self)
src/graph/shortest/ew_digraph.rs:19
Function
Kruskal_mst
()
tests/test_graph_mst.rs:59
Function
LSD_radix_sort
()
tests/test_strings.rs:12
Function
LSD_radix_sort_i32
()
tests/test_strings.rs:30
Function
MSD_best_case
(b: &mut Bencher)
benches/strings.rs:75
Function
MSD_radix_sort
()
tests/test_strings.rs:41
Function
MSD_worst_case
(b: &mut Bencher)
benches/strings.rs:66
Function
Prim_mst
()
tests/test_graph_mst.rs:45
Function
acyclic_lp
()
tests/test_shortest_paths.rs:112
Function
acyclic_sp
()
tests/test_shortest_paths.rs:89
Function
alphabet
()
tests/test_alphabet.rs:7
Function
arbitrage
()
tests/test_shortest_paths.rs:185
Method
avg_degree
compute average degree
src/graph/undirected/graph.rs:88
Function
bfs_paths
()
tests/test_undirected_graph.rs:91
Function
bfs_paths
()
tests/test_directed_graph.rs:58
Function
binary_search
()
tests/test_search.rs:4
Function
binary_search_tree_min_max
()
tests/test_bst_tree.rs:22
Function
binary_search_tree_succ_pred
()
tests/test_bst_tree.rs:39
Function
brute_force_search
()
tests/test_strings.rs:344
Function
bst_tree_height
()
tests/test_bst_tree.rs:78
Function
build_binary_search_tree
()
tests/test_bst_tree.rs:6
Function
build_heap
()
tests/test_common_heap.rs:20
Method
build_in_level
(vec: &[&str])
src/tree/binary/builder/level.rs:20
Method
build_tournament_tree
(data: &[K])
src/tree/binary/builder/tournament.rs:17
← previous
next →
201–300 of 655, ranked by callers