Cell missing but content still runs

Hi, I accidentally refreshed my Jupyter Notebook while working on it, and a cell went missing. However when I run this cell (i.e print variables that was exclusively in that cell), it still prints. Can anyone help with retrieving the lost cell?

Thank you!

You can get the previously-executed inputs to the IPython kernel with the In variable. See https://jakevdp.github.io/PythonDataScienceHandbook/01.04-input-output-history.html, for example.

Try print(In), or find a specific execution indexing into the array, like In[30].

2 Likes