Skip to content

Commit a6694d4

Browse files
authored
improve docs for IPython mode (#48314)
1 parent 5f40f15 commit a6694d4

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

stdlib/REPL/docs/src/index.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -629,7 +629,20 @@ atreplinit() do repl
629629
end
630630
```
631631

632-
to your `startup.jl` file.
632+
to your `startup.jl` file. In `IPython` mode the variable `Out[n]` (where `n` is an integer) can be used to refer to earlier results:
633+
634+
```julia-repl
635+
In [1]: 5 + 3
636+
Out[1]: 8
637+
638+
In [2]: Out[1] + 5
639+
Out[2]: 13
640+
641+
In [3]: Out
642+
Out[3]: Dict{Int64, Any} with 2 entries:
643+
2 => 13
644+
1 => 8
645+
```
633646

634647
## TerminalMenus
635648

0 commit comments

Comments
 (0)