上QQ阅读APP看书,第一时间看更新
Consulting Rust documentation
The quickest way to find more detailed information about a Rust topic is to browse to the documentation screen of the Standard Library, http://doc.rust-lang.org/std/.
On the left, you can find a listing of all crates available, which you can browse for more details. But most useful is the search box at the top: type in a few letters or a word to get a number of useful references.
Exercises:
Try to change the value of a constant. Of course this is not allowed, what error do you get? (For an example see Chapter2/exercises/change_constant.rs) .
Look up the println! macro in the documentation.
Read the fmt specification and write a program that will print value 3.2f32 as +003.20 (see Chapter2/exercises/formatting.rs ).
Try to change the value of a constant. Of course this is not allowed, what error do you get? (For an example see Chapter2/exercises/change_constant.rs) .
Look up the println! macro in the documentation.
Read the fmt specification and write a program that will print value 3.2f32 as +003.20 (see Chapter2/exercises/formatting.rs ).