14 lines
262 B
Markdown
14 lines
262 B
Markdown
# Swap keyword in fa
|
|
|
|
`Swap` keyword will swap two elements on the stack
|
|
|
|
`Swap` takes no arguments
|
|
|
|
Example of the `swap` keyword:
|
|
|
|
```fa
|
|
"E" swap drop
|
|
```
|
|
|
|
This will swap the places with the string (`"E"`) and the
|
|
length (`1`) so it will be basically `69 pop`
|