sympy.interactive -- rework init_printing to support different stringifiers
This allows us to hook different printing functions as display_hook.
At present init_session supports:
o pprint (isympy -p UNICODE | ASCII | any)
o sstrrepr (isympy -p no)
an example which speaks for itself for `isympy -p no`:
In [1]: x**2
Out[1]: x**2
In [2]: set(['abc', 1, x, x**2, x**3, x**4, y, x**5])
Out[2]: set(['abc', 1, x, y, x**2, x**3, x**4, x**5])
i.e. everything works like in usual Python session without pprint, but
containers are printed with human-friendly / hash-stable ordering.
we'll reuse this property to robustify doctests in the next patch.
Signed-off-by: Kirill Smelkov <kirr@landau.phys.spbu.ru>
Signed-off-by: Ondrej Certik <ondrej@certik.cz>