r/programming • u/ttsiodras • Dec 23 '12
Simulating a solar system with Python
http://users.softlab.ntua.gr/~ttsiod/gravityRK4.html
244
Upvotes
r/programming • u/ttsiodras • Dec 23 '12
View all comments
Show parent comment
13
u/ttsiodras Dec 23 '12
When I first started blogging almost a decade ago, I made a custom Perl script that parses my own "mini-language": basically, markdown with magic sections (marked with '@@py@@ .... @@' for python code, or '@@c++@@ ...' for C++, etc). The script extracts these sections, invokes source-highlight (it used to invoke webcpp) and merges the results in the HTML generated from the markdown. Not only is it easier to author posts this way, I also get my HTML to be w3c-valid for free (see the links at the bottom of my site's pages).