- Rust Quick Start Guide
- Daniel Arbuckle
- 163字
- 2021-06-10 19:46:04
Expressions
The instructions that tell the computer to do something in a Rust program are almost all expressions. An expression tells the computer how to compute a particular value, and produces that value as its result. In math, 2 + 2 is an expression with a resulting value of 4. Similarly, (2 + 2) - 1 is an expression with a resulting value of 3, which is itself made up of an addition expression and a subtraction expression. In Rust, the same basic idea applies: expressions tell the computer how to find a value, and they can be combined together, because using an expression that produces a value has the same result as using that value directly, just as writing (2 + 2) - 1 has the same result as writing 4 - 1.
Not all expressions in Rust look like math, though. Rust is a programming language, not just a calculator. It's the idea of expressions, which combine values to produce new values, that matters.
- ASP.NET Core Essentials
- PostgreSQL技術內幕:事務處理深度探索
- Python機器學習基礎教程
- Test-Driven Development with Django
- Learning Docker Networking
- Java 9 Programming By Example
- 測試架構師修煉之道:從測試工程師到測試架構師
- 超簡單:Photoshop+JavaScript+Python智能修圖與圖像自動化處理
- 實戰Python網絡爬蟲
- Using Yocto Project with BeagleBone Black
- 3D Printing Designs:The Sun Puzzle
- Beginning C# 7 Hands-On:The Core Language
- MySQL從入門到精通
- Cocos2D Game Development Essentials
- Learning Java Lambdas