Ask Your Question

Revision history [back]

Show both sides of a function definition

When I define a function and show on it, I only get the right hand side. Is there a way to show the full definition? Basically I want to show pretty-printed version of the code used to define the function. I'm using a Jupyter notebook. I could simply rewrite it in a markdown cell of course, but that's tedious and error-prone my real use-case which is more complex than this toy example.

f(x) = a*x^2 + b*x + c
show(f)

What I get:

𝑥 ↦ 𝑎𝑥2+𝑏𝑥+𝑐

What I want:

f(𝑥) = 𝑎𝑥2+𝑏𝑥+𝑐