Now type "meta-x mmm-mode" to enable the MMM minor mode. Every docstring will be higlighted using mmm-default-submode-face, and doctest-mode's syntax highlighting will be applied to any doctest examples within the docstrings. Note that "MMM" is now shown in the Emacs modeline. (Note: If you have set the Emacs variable mmm-global-mode to "t" or "maybe" then the MMM minor mode will be turned on automatically.) |
def x_intercept(m, b): """ Return the x intercept of the line y=m*x+b. >>> x_intercept(3, 6) -2.0 >>> x_intercept(-4, 2) 0.5 """ return -float(b)/m . ISO8---Emacs: mytest.py (Python MMM Font)----L11--All---------- |