mirror of
https://github.com/krahets/hello-algo.git
synced 2026-09-01 12:47:14 +00:00
Bug fixes and improvements (#1380)
* preorder, inorder, postorder -> pre-order, in-order, post-order * Bug fixes * Bug fixes * Update what_is_dsa.md * Sync zh and zh-hant versions * Sync zh and zh-hant versions. * Update performance_evaluation.md and time_complexity.md * Add @khoaxuantu to the landing page. * Sync zh and zh-hant versions * Add @ khoaxuantu to the landing page of zh-hant and en versions.
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
/* 頂點型別 */
|
||||
#[derive(Copy, Clone, Hash, PartialEq, Eq)]
|
||||
pub struct Vertex {
|
||||
pub val: i32
|
||||
pub val: i32,
|
||||
}
|
||||
|
||||
/* 輸入值串列 vals ,返回頂點串列 vets */
|
||||
@@ -18,4 +18,4 @@ pub fn vals_to_vets(vals: Vec<i32>) -> Vec<Vertex> {
|
||||
/* 輸入頂點串列 vets ,返回值串列 vals */
|
||||
pub fn vets_to_vals(vets: Vec<Vertex>) -> Vec<i32> {
|
||||
vets.into_iter().map(|vet| vet.val).collect()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user