Skip to content

Commit

Permalink
tour: updated description for if statement in flowcontrol article
Browse files Browse the repository at this point in the history
Existing article is misleading, in new change clear description is provided.

Fixes: golang/tour#743
  • Loading branch information
sagar23sj committed Jun 15, 2021
1 parent d831351 commit fe495cd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tour/content/flowcontrol.article
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ If you omit the loop condition it loops forever, so an infinite loop is compactl

* If

Go's `if` statements are like its `for` loops; the expression need not be
surrounded by parentheses `(`)` but the braces `{`}` are required.
The expression does not need to be surrounded by parentheses `(`)` in Go's `if` statement and
the braces `{`}` are always required.

.play flowcontrol/if.go

Expand Down

0 comments on commit fe495cd

Please sign in to comment.