From f047e19d0fa7649a0c294f5e299d14b6199738bf Mon Sep 17 00:00:00 2001 From: Kristoffer Date: Tue, 17 Jan 2023 13:55:32 +0100 Subject: [PATCH] improve docs for IPython mode --- stdlib/REPL/docs/src/index.md | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/stdlib/REPL/docs/src/index.md b/stdlib/REPL/docs/src/index.md index d696c069fbdb7..a23b8f224a6cb 100644 --- a/stdlib/REPL/docs/src/index.md +++ b/stdlib/REPL/docs/src/index.md @@ -629,7 +629,20 @@ atreplinit() do repl end ``` -to your `startup.jl` file. +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: + +```julia-repl +In [1]: 5 + 3 +Out[1]: 8 + +In [2]: Out[1] + 5 +Out[2]: 13 + +In [3]: Out +Out[3]: Dict{Int64, Any} with 2 entries: + 2 => 13 + 1 => 8 +``` ## TerminalMenus