Code is enclosed within tags:
<div style="overflow-x: scroll ">
<table bgcolor="#ffffb0" border="0"
width="100%" padding="4">
<tbody>
<tr>
<d>
<pre style=" hidden;font-family:monaco;">
..
</pre>
</table>
</div>
I liked this method because the output is monospaced, and the background colored according to the type of code (Python, R, output, etc).
I guess I'll have to look into CSS. If anyone has a good set of instructions to point me to, I'd be grateful.