Here is regular text. Now for some Ruby:
require 'redcarpet'
markdown = Redcarpet.new("Hello World!")
puts markdown.to_html| import rg | |
| from random import seed,randint | |
| class Robot: | |
| def __init__(self): | |
| self.oldturn = -1 | |
| seed(None) | |
| def act(self, game): | |
| if game.turn != self.oldturn: |
| #!/usr/bin/env python | |
| from sys import argv as args | |
| original = args[1] | |
| index = args[2] | |
| size = int(args[3]) | |
| dedup = args[4] | |
| def dedup(index, original, dedup, size): |
| default: | |
| gcc question.c -o question -Wall -Werror | |
| ./question |
| default: | |
| true && printf '\t\x1b[32mBuild Succeeded\x1b[0m\n' | |
| true && bash -c "printf '\t\x1b[32mBuild Succeeded\x1b[0m\n'" | |
| printf '\t\x1b[32mBuild Succeeded\x1b[0m\n' |
| #!/usr/bin/env python | |
| from PIL import Image, ImageDraw | |
| im = Image.new("RGB", (1024,1024), "white") # you could also Image.open(...) | |
| drawer = ImageDraw.Draw(im) | |
| # draw connecting line | |
| drawer.line((256,256,512,512), fill=96, width=5) |
| <html> | |
| <head> | |
| <link rel="stylesheet" href="http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.css" /> | |
| <script src="http://code.jquery.com/jquery-1.9.1.min.js"></script> | |
| <script src="http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.js"></script> | |
| <script> | |
| function switcher() { | |
| console.log('entering switcher()') | |
| $.mobile.changePage($("#page2")); | |
| console.log('switcher() just ran'); |
| default: | |
| python setup.py build | |
| ln -fs build/lib.linux-x86_64-2.7/hello.so hello.so | |
| python -c 'import hello; hello.func("it is workingses!")' | |
| test_hello: | |
| g++ test_main.cpp \ | |
| hello_world.cpp \ | |
| -o test_main |
| #!/usr/bin/env python | |
| import json | |
| import subprocess | |
| import tempfile | |
| from flask import Flask, url_for, redirect, render_template, request | |
| from os import fdopen,remove | |
| app = Flask(__name__) |
| #!/usr/bin/env python | |
| graph = { | |
| 'N1': {'N2': 1}, | |
| 'N12':{'N13':1}, | |
| 'N2': {'N4': 1, 'N13':1}, | |
| 'N4': {'N5': 1, 'N12': 1}, | |
| 'N5': {'N6': 1}, | |
| 'N6': {'N7': 1}, |
Here is regular text. Now for some Ruby:
require 'redcarpet'
markdown = Redcarpet.new("Hello World!")
puts markdown.to_html