blob: 0c963223d110277c256566cddc96b289f7f1d86f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
// functions5.rs
//
// Execute `rustlings hint functions5` or use the `hint` watch subcommand for a
// hint.
fn main() {
let answer = square(3);
println!("The square of 3 is {}", answer);
}
fn square(num: i32) -> i32 {
num * num;
}
|