Cell magic to highlight different languages
pip install --no-cache-dir git+https://github.com/Digiklausur/syntax_highlight
jupyter nbextension install --py --sys-prefix syntax_highlight
jupyter nbextension enable --py --sys-prefix syntax_highlight
First import it:
import syntax_highlight
Then use it in a cell:
%%syntax java
Supported languages are c
, java
, sql
.