|
| 1 | +# RUST BASIC Powered By AI |
| 2 | + |
| 3 | +Welcome to the **Rust Basics** repository, a collection of foundational Rust programming topics. This project is designed to help learners get started with Rust by exploring key concepts such as variables, data types, control flow, and more. |
| 4 | + |
| 5 | +## Overview |
| 6 | + |
| 7 | +Rust is a systems programming language that emphasizes performance, safety, and concurrency. This repository will guide you through some of the most important and basic features of the language. |
| 8 | + |
| 9 | +## Topics Covered |
| 10 | + |
| 11 | +Here is an organized list of topics with a brief description for each: |
| 12 | + |
| 13 | +| Topic | Description | |
| 14 | +| ------------------------ | ------------------------------------------------------------------------------------------ | |
| 15 | +| **Hello World** | A simple "Hello, World!" program to get started with Rust. | |
| 16 | +| **Cargo** | Learn how to use Cargo, the Rust package manager and build system. | |
| 17 | +| **Unit Test** | Writing and running unit tests to ensure code correctness. | |
| 18 | +| **Variable** | Understanding variable declarations, mutability, and scoping. | |
| 19 | +| **Comment** | Using comments in Rust code for clarity and documentation. | |
| 20 | +| **Data Type** | Exploring the basic data types available in Rust (e.g., integers, floats, booleans, etc.). | |
| 21 | +| **Number** | Working with numeric types, including integer and floating-point numbers. | |
| 22 | +| **Numeric Operations** | Performing basic arithmetic operations like addition, subtraction, and multiplication. | |
| 23 | +| **Boolean** | Understanding boolean values and their role in logic and conditions. | |
| 24 | +| **Comparison Operators** | Using comparison operators (e.g., `==`, `!=`, `<`, `>`) to compare values. | |
| 25 | +| **Boolean Operators** | Using logical boolean operators (AND, OR, NOT) to combine boolean values. | |
| 26 | +| **Char** | Working with characters and understanding the char data type. | |
| 27 | +| **Array** | Introduction to arrays in Rust and how to work with them. | |
| 28 | +| **Constant** | Defining and using constants in Rust to store fixed values. | |
| 29 | +| **Variable Scope** | Understanding the scope of variables and how they affect code behavior. | |
| 30 | + |
| 31 | +## How to Run the Code |
| 32 | + |
| 33 | +To run the examples in this repository: |
| 34 | + |
| 35 | +1. Clone the repository to your local machine: |
| 36 | + |
| 37 | + ```bash |
| 38 | + git clone https://github.com/yogithesymbian/rust_basic.git |
| 39 | + cd rust_basic |
| 40 | + ``` |
| 41 | + |
| 42 | +2. Make sure you have Rust installed on your machine. If not, you can install it from [Rust's official site](https://www.rust-lang.org/learn/get-started). |
| 43 | + |
| 44 | +3. Each topic is separated into a `src` file (e.g., `src/hello_world.rs`, `src/cargo.rs`). You can compile and run the code in any of these files with Cargo: |
| 45 | + |
| 46 | + ```bash |
| 47 | + cargo run --example hello_world |
| 48 | + ``` |
| 49 | + |
| 50 | + Replace `hello_world` with the name of any example you want to run. |
| 51 | + |
| 52 | +## Contributing |
| 53 | + |
| 54 | +Feel free to fork the repository, make changes, and create pull requests to contribute new examples, improve documentation, or fix bugs. |
| 55 | + |
| 56 | +## License |
| 57 | + |
| 58 | +This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. |
| 59 | + |
| 60 | +--- |
| 61 | + |
| 62 | +Thank you for exploring Rust with this basic guide! 🎉 |
0 commit comments