Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/derekbanas/Rust-Tutorial
/ functions
Functions
24 in github.com/derekbanas/Rust-Tutorial
⨍
Functions
24
◇
Types & classes
8
↓ 1 callers
Function
change_string
(name: &mut String)
main.rs:134
↓ 1 callers
Function
customer
(the_bank: Arc<Mutex<Bank>>)
main.rs:1072
↓ 1 callers
Function
get_2
Return multiple values
main.rs:121
↓ 1 callers
Function
get_sum
You can pass arguments to functions
main.rs:103
↓ 1 callers
Method
left
(mut self, node: TreeNode<T>)
main.rs:939
↓ 1 callers
Function
order_food
This is the public function that allows our other file access
mod.rs:56
↓ 1 callers
Function
print_return_str
(x: String)
main.rs:129
↓ 1 callers
Function
print_str
(x: String)
main.rs:125
↓ 1 callers
Method
right
(mut self, node: TreeNode<T>)
main.rs:944
↓ 1 callers
Function
say_hello
----- FUNCTIONS ----- You can define functions before or after main
main.rs:98
↓ 1 callers
Function
seat_at_table
This function is private
mod.rs:32
↓ 1 callers
Function
serve_customer
(cust_pizza: super::Pizza)
mod.rs:48
↓ 1 callers
Function
take_order
Making help_customer public doesn't make this child function public so we must also make it public
mod.rs:38
↓ 1 callers
Function
withdraw
(the_bank: &Arc<Mutex<Bank>>, amt:f32)
main.rs:1059
Method
area
self allows us to refer to parameters for this struct
main.rs:706
Function
get_sum_2
Return a value
main.rs:108
Function
get_sum_3
You can also use return
main.rs:116
Function
get_sum_gen
We get 2 generic types of the same type and return that same type
main.rs:157
Method
is_weekend
(&self)
main.rs:476
Method
lunch
(topping: &str)
mod.rs:20
Function
main
()
main.rs:161
Method
new
Constructor
main.rs:701
Function
sum_list
This function sums values in a list (Receives reference to list)
main.rs:140
Function
use_func
You can pass closures to functions
main.rs:861