Public feed #724068

Untitled

public text v1 · immutable
Raw Edit
·published 2007-10-03 09:05 UTC
rendered paste body
charset = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"

def redu(inp):
    ostr = ""
    while inp >= len(charset):
        k = inp % (len(charset) + 1)
        ostr += charset[k - 1]
        inp /= len(charset)
        lastchar = k
        print k

    print inp
    ostr += charset[inp]
    
    return ostr