An open API service indexing awesome lists of open source software.

https://github.com/0xsaksham/programming-concepts-rust

Rust code snippets showcasing arrow functions with parentheses, function calls, and a demonstration of statements vs. expressions. 🦀
https://github.com/0xsaksham/programming-concepts-rust

practice-programming rust rust-lang

Last synced: 10 months ago
JSON representation

Rust code snippets showcasing arrow functions with parentheses, function calls, and a demonstration of statements vs. expressions. 🦀

Awesome Lists containing this project

README

          

**Programming Concepts Rust**

**Description**

This repository contains a collection of Rust functions demonstrating various concepts of the language.

**Usage**

To run the code, save the files in a Rust project and call the functions from the `main` function.

**Examples**

* Calling the `plus_one` function:

```rust
let x = plus_one(4);
println!("x: {}", x);
```

* Calling the `another_function` function:

```rust
another_function();
```

* Calling the `parameter_function` function:

```rust
parameter_function(6);
```

* Calling the `two_parameter_function` function:

```rust
two_parameter_function(22, 'Z');
```

**Contributing**

Contributions to this repository are welcome. Please create an issue or pull request to submit your changes.

**License**

This project is licensed under the MIT License.