Skip to content

Commit

Permalink
Update ch03-03-how-functions-work.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Riahiamirreza authored Dec 8, 2023
1 parent ff61a87 commit 1cecdf8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/ch03-03-how-functions-work.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,9 @@ of functions.

* **Statements** are instructions that perform some action and do not return
a value.
* **Expressions** evaluate to a resultant value. Let’s look at some examples.
* **Expressions** evaluate to a resultant value.

Let’s look at some examples.
We’ve actually already used statements and expressions. Creating a variable and
assigning a value to it with the `let` keyword is a statement. In Listing 3-1,
`let y = 6;` is a statement.
Expand Down Expand Up @@ -252,4 +253,4 @@ definition and results in an error. In this output, Rust provides a message to
possibly help rectify this issue: it suggests removing the semicolon, which
would fix the error.

{{#quiz ../quizzes/ch03-03-functions-sec2-expressions.toml}}
{{#quiz ../quizzes/ch03-03-functions-sec2-expressions.toml}}

0 comments on commit 1cecdf8

Please sign in to comment.