Skip to content

Commit

Permalink
Remove line numbers from ternary expressions example
Browse files Browse the repository at this point in the history
  • Loading branch information
Sainan committed Oct 25, 2024
1 parent f144c9c commit 4fcc06c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/New Features/Ternary Expressions.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
sidebar_position: 1
---
Ternary expressions behave identical as to how they would in C. They introduce no new keywords.
```pluto showLineNumbers title="Old Code"
```pluto title="Old Code"
local max
if a > b then
max = a
else
max = b
end
```
```pluto showLineNumbers title="New Code"
```pluto title="New Code"
local max = a > b ? a : b
```
#### [Try It Yourself](https://pluto-lang.org/web/#code=local%20a%20%3D%206%0Alocal%20b%20%3D%209%0A%0Alocal%20max%20%3D%20a%20%3E%20b%20%3F%20a%20%3A%20b%0A%0Aprint(max))
Expand Down

0 comments on commit 4fcc06c

Please sign in to comment.