Skip to content

Instantly share code, notes, and snippets.

View mrtopf's full-sized avatar

Christian Scholz mrtopf

View GitHub Profile
@mrtopf
mrtopf / .vimrc
Created May 4, 2013 15:37
meine .vimrc #cool
filetype off
"call pathogen#runtime_append_all_bundles()
"filetype plugin indent on
set nocompatible
set modelines=0
set softtabstop=4
set tabstop=4
@mrtopf
mrtopf / gist:5228439
Last active December 15, 2015 08:09
python script to compute profit for planetary interaction converting toxic metals and precious metals to enriched uranium
#coding=utf-8
import locale
locale.setlocale(locale.LC_ALL, 'en_US')
"""
Compute the profit per day for enriched uranium or other stuff
"""
input price 1: 410 ISK
input price 2: 676 ISK
output price : 12,525 ISK
net profit per installation per hour: 19,184 ISK
P1 items to import per batch: 80
P2 items to export per batch: 5
Import fee per batch 2,000 ISK
Export fee per batch 4,500 ISK
import sys
from elementtree.ElementTree import parse
class Record(object):
"""the final record"""
def _toint(self, s):
"""convert a financial number to int"""
if s=="-":
return -1
labertasche:openid cs$ /opt/python/2.6/bin/virtualenv test
New python executable in test/bin/python
Please make sure you remove any previous custom paths from your /Users/cs/.pydistutils.cfg file.
Installing setuptools............done.
labertasche:openid cs$ . test/bin/activate
(test)labertasche:openid cs$ easy_install repoze.who.plugins.openid
Searching for repoze.who.plugins.openid
Reading http://pypi.python.org/simple/repoze.who.plugins.openid/
Reading http://quantumcore.org/docs/repoze.who.plugins.openid
Best match: repoze.who.plugins.openid 0.5.2
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<script>
var ball = {
x: 100,
y: 100,
dx : 4,
dy : 4,
};