diff options
| author | mo8it <mo8it@proton.me> | 2024-05-21 02:43:18 +0200 |
|---|---|---|
| committer | mo8it <mo8it@proton.me> | 2024-05-21 02:43:18 +0200 |
| commit | d0b843d6c4a99636d3dc6caf3ceebea14cb3b07d (patch) | |
| tree | 2021b096bdd07d37abbf71ed1df3b0b58753f67a /solutions/02_functions/functions2.rs | |
| parent | 0f4c42d54ea7322a4ee0ae7036c058c3061e80e9 (diff) | |
Add solutions to functions
Diffstat (limited to 'solutions/02_functions/functions2.rs')
| -rw-r--r-- | solutions/02_functions/functions2.rs | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/solutions/02_functions/functions2.rs b/solutions/02_functions/functions2.rs index 4e18198..f14ffa3 100644 --- a/solutions/02_functions/functions2.rs +++ b/solutions/02_functions/functions2.rs @@ -1 +1,11 @@ -// Solutions will be available before the stable release. Thank you for testing the beta version 🥰 +// The type of function arguments must be annotated. +// Added the type annotation `u64`. +fn call_me(num: u64) { + for i in 0..num { + println!("Ring! Call number {}", i + 1); + } +} + +fn main() { + call_me(3); +} |
