ASKSAGE: Sage Q&A Forum - Individual question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Thu, 09 May 2013 10:39:06 -0500See if code running in notebook?http://ask.sagemath.org/question/10095/see-if-code-running-in-notebook/Is it possible for code to check if it's being run from the Notebook or from the Interactive Shell? (I want to format the output differently in the two cases.)Thu, 09 May 2013 10:07:00 -0500http://ask.sagemath.org/question/10095/see-if-code-running-in-notebook/Answer by tmonteil for <p>Is it possible for code to check if it's being run from the Notebook or from the Interactive Shell? (I want to format the output differently in the two cases.)</p>
http://ask.sagemath.org/question/10095/see-if-code-running-in-notebook/?answer=14906#post-id-14906Yes it is possible, you can see two possibilities in [this post](http://ask.sagemath.org/question/2184/is-there-an-existing-function-detecting-the-use-of).Thu, 09 May 2013 10:39:06 -0500http://ask.sagemath.org/question/10095/see-if-code-running-in-notebook/?answer=14906#post-id-14906