Add multiple parameters

This commit is contained in:
Manuel Thalmann 2024-10-14 18:26:04 +02:00
parent 4bc2d864e1
commit 683e905215

View file

@ -1,7 +1,7 @@
fn main() {
another_function(5);
print_labeled_measurement(5, 'h');
}
fn another_function(x: i32) {
println!("The value of x is: {x}");
fn print_labeled_measurement(value: i32, unit_label: char) {
println!("The measurement is: {value}{unit_label}");
}