update readme.md

This commit is contained in:
sunface
2022-03-15 09:36:42 +08:00
parent e2a380da52
commit bbf3829a3b
6 changed files with 32 additions and 11 deletions

View File

@ -1,8 +1,21 @@
# Rust By Practice <div align="center">
<img height="150" src="https://github.com/sunface/rust-by-practice/blob/master/assets/logo.png">
<div>
<span>English</span>
<span> | </span>
<a href="https://github.com/sunface/rust-by-practice/blob/master/zh-CN/src/why-exercise.md">中文</a>
</div>
<p align="center">Practice Rust with challenging examples, exercises and projects</p>
</div>
<div align="center">
[![Stars Count](https://img.shields.io/github/stars/sunface/rust-by-practice?style=flat)](https://github.com/sunface/rust-by-practice/stargazers) [![Forks Count](https://img.shields.io/github/forks/sunface/rust-by-practice.svg?style=flat)](https://github.com/naaive/orange/network/members)
[![LICENSE](https://img.shields.io/badge/license-mit-green?style=flat)](https://github.com/sunface/rust-by-practice/blob/master/LICENSE)
</div>
This book was designed for easily diving into and get skilled with Rust, and it's very easy to use: All you need to do is to make each exercise compile without ERRORS and Panics ! This book was designed for easily diving into and get skilled with Rust, and it's very easy to use: All you need to do is to make each exercise compile without ERRORS and Panics !
> 🎊 Updated on 2022-03-14: Add Chapter [Crate and Module](https://practice.rs/crate-module/intro.html)
## Reading online ## Reading online

BIN
assets/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

View File

@ -19,7 +19,7 @@ version = "0.1.0"
edition = "2021" edition = "2021"
``` ```
> Note! We will this package across the whole chapter > Note! We will use this package across the whole chapter as a practice project.
2. 🌟 Create a package with below layout: 2. 🌟 Create a package with below layout:
```shell ```shell
@ -90,11 +90,11 @@ After this step, there should be two crates in package `hello-package`: **a bina
├── Cargo.toml ├── Cargo.toml
├── Cargo.lock ├── Cargo.lock
├── src ├── src
│ ├── │ ├── __
│ ├── │ ├── __
│ └── │ └── __
│ └── │ └── __
│ └── │ └── __
├── tests # directory for integrated tests files ├── tests # directory for integrated tests files
│ └── some_integration_tests.rs │ └── some_integration_tests.rs
├── benches # dir for benchmark files ├── benches # dir for benchmark files
@ -103,4 +103,7 @@ After this step, there should be two crates in package `hello-package`: **a bina
└── simple_example.rs └── simple_example.rs
``` ```
Yep, as you can see, the above package structure is very standard and is widely used in many Rust projects. Yep, as you can see, the above package structure is very standard and is widely used in many Rust projects.
> You can find the solutions [here](https://github.com/sunface/rust-by-practice) (under the solutions path), but only use it when you need it :)

View File

@ -190,4 +190,6 @@ fn main() {
assert_eq!(__, "sit down please"); assert_eq!(__, "sit down please");
assert_eq!(__,"yummy yummy!"); assert_eq!(__,"yummy yummy!");
} }
``` ```
> You can find the solutions [here](https://github.com/sunface/rust-by-practice) (under the solutions path), but only use it when you need it :)

View File

@ -63,4 +63,7 @@ pub mod a {
``` ```
### Full Code ### Full Code
The full code of `hello-package` is [here](https://github.com/sunface/rust-by-practice/tree/master/practices/hello-package). The full code of `hello-package` is [here](https://github.com/sunface/rust-by-practice/tree/master/practices/hello-package).
> You can find the solutions [here](https://github.com/sunface/rust-by-practice) (under the solutions path), but only use it when you need it :)