Exercise 13

This commit is contained in:
akshitgautam42 2023-11-11 20:30:25 +05:30
parent 7b53c94328
commit 1aed8d48f6

View File

@ -3,13 +3,13 @@
// Execute `rustlings hint functions5` or use the `hint` watch subcommand for a // Execute `rustlings hint functions5` or use the `hint` watch subcommand for a
// hint. // hint.
// I AM NOT DONE
fn main() { fn main() {
let answer = square(3); let answer:i32 = square(3);
println!("The square of 3 is {}", answer); println!("The square of 3 is {}", answer);
} }
fn square(num: i32) -> i32 { fn square(num: i32) -> i32 {
num * num; (num * num)
} }