How do I reset the Jupyter/IPython input prompt numbering?

前端 未结 9 1114
孤街浪徒
孤街浪徒 2021-02-02 05:08

I just wrote my first extensive Python tutorial using IPython notebooks. All went well, except I did a lot of testing and moving blocks around. How do I reset the In [

9条回答
  •  终归单人心
    2021-02-02 05:40

    For those coming from Google:

    %reset
    

    This is useful when you want to reset all variables after a certain point in the notebook. It is going to ask if you are sure that you want to reset. If you want to force reset without asking, then use:

    %reset -f
    

提交回复
热议问题