Skip to content

Instantly share code, notes, and snippets.

@moorsalin
moorsalin / onion_url.py
Last active August 19, 2017 03:17
Generate random onion url and add to clipboard
'''
tor url
16 chars
[a-z2-7]{16}
how to generate every possible tor url?
https://stackoverflow.com/questions/579687/how-do-i-copy-a-string-to-the-clipboard-on-windows-using-python
'''
from tkinter import Tk
@moorsalin
moorsalin / buzzfeed_api.md
Created December 21, 2016 03:14
BuzzFeed API - hackNY hackathon
                                               .--.
                                               `.  \
                                                 \  \
                                                  .  \
                                                  :   .
                                                  |    .
                                                  |    :
                                                  |    |
  ..._  ___                                       |    |
 `."".`''''""--..___ | |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
/*
* Define decent number
* digits are either 3 or 5
* quantity of 3 is divisible by 5
* quantity of 5 is divisible by 3
*/
#!/usr/bin/env python3
#written after relaxing
import os, random
board = [str(i) for i in range(9)]
def checkIfWin(board):
#diagnols
diag1,diag2 = set(),set()
for i in range(3):
pos = i*3 + i
@moorsalin
moorsalin / links.txt
Last active March 2, 2025 17:58
@moorsalin
moorsalin / turing-tweet.js
Last active August 29, 2015 14:27
A tweetable turing machine
/**
* Here's a turing machine that fits into a tweet with an example program.
* Tweet: https://twitter.com/mrrrgn/status/630419814666780673
* Gif: http://i.imgur.com/4t31zA2.gif
* Turing machines: https://www.youtube.com/watch?v=dNRDvLACg5Q
*
* This this is neat? Consider following me for more computer silliness:
* twitter.com/mrrrgn or visit my blog linuxpoetry.com
**/
#p1
def p1(nums):
fsum = 0
wsome = 0
for num in nums:
fsum += num
c = 0
while c < len(nums):
wsome += nums[c]
@moorsalin
moorsalin / 4chanthreadgrab.py
Last active January 1, 2016 22:49
Grabbing pol threads to save for analysis later
#!/usr/bin/python2.7
import json, urllib2, time, pickle
FOURCHAN_BASE_URL = 'http://a.4cdn.org/pol/threads.json'
FOURCHAN_THREAD_URL = 'http://a.4cdn.org/pol/res/'
PICKLE_FILE = ''
'''
Thread class
represents a thread containing