latex and python code