3 ms·
emacs org mode will work in the terminal. For example, in an org doc you can have something like this: * Python #+BEGIN_SRC python :results output def m
by kagevf 4y ago
emacs org mode will work in the terminal.
For example, in an org doc you can have something like this:
* Python
#+BEGIN_SRC python :results output
def myTest(a):
return a + 2
print (myTest(8))
#+END_SRC
#+RESULTS:
: 10
#+BEGIN_SRC python :results output
def check_even(n):
if n % 2 == 0:
print("even")
else:
print("odd")
check_even(5)
check_even(2)
#+END_SRC
#+RESULTS:
: odd
: even