From anonymous, 1 Month ago, written in Python.
Embed
  1. def dec(bytestr):
  2.     positions = {
  3.         0: 7,
  4.         1: 5,
  5.         2: 4,
  6.         3: 3,
  7.         4: 6,
  8.         5: 2,
  9.         6: 1,
  10.         7: 0,
  11.     }
  12.     res = []
  13.     for c in bytestr:
  14.         outc = 0x2800
  15.         for i in range(0, 8):
  16.             if c & (1 << i):
  17.                 outc |= (1 << positions[i])
  18.         res.append(outc)
  19.  
  20.     return ''.join([chr(b) for b in res])

Replies to Untitled rss

Title Name Language When
Re: Untitled anonymous python 1 Month ago.