This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# A secret HTTP server that only serves some content of a page | |
# when a decent Authorization header has been sent with the | |
# correct data. | |
# By itself will not tell the client that there needs to be an Authorization | |
# header. | |
# woo, secret spy networks! | |
# boxmein 2013 - free to use - idk | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# split a square defined by its side w into four equals | |
# for Doxin | |
class Point: | |
def __init__(self, x, y): | |
self.x = x | |
self.y = y | |
class Square: | |
def __init__(self, x1, y1, x2, y2): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- encoding:utf8 -*- | |
def magic(width): | |
lines = [] | |
oldwidth = width | |
# going downwards | |
width += 2 | |
while width-2 > 0: | |
lines.append(str.center("* " * (width-2), oldwidth*2)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
A script that demonstrates integer division in C. | |
Prints two numbers, the first with integer division | |
and the second with floating division. | |
Integer division is achieved by having the divisor | |
be an integer. | |
Compile with anything really. Running produces the | |
following output: | |
0 0.333333 | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys, array | |
# Name to character reference | |
# you can like | |
# modify me | |
# modify me a lot | |
# i likes it | |
ch = { | |
'mniip': '<', | |
'Ristovski': '>', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# http://esolangs.org/wiki/Unnecessary | |
# Unnecessary interpreter for the unnecessary language. | |
# Usage: unnecessary.rb <file> | |
puts "Error: program file exists" if ARGV[0] and File.exist? ARGV[0] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Stripped down version of minibot. | |
// Use as baseline for other bots ! | |
/*jslint node: true */ | |
console.log("-- working directory: " + process.cwd()); | |
var net = require("net"), | |
fs = require("fs"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
states = %w(Alabama Alaska Arizona Arkansas California Colorado | |
Connecticut Delaware Florida Georgia Hawaii Idaho Illinois Indiana Iowa | |
Kansas Kentucky Louisiana Maine Maryland Massachusetts Michigan Minnesota | |
Mississippi Missouri Montana Nebraska Nevada NewHampshire NewJersey | |
NewMexico NewYork NorthCarolina NorthDakota Ohio Oklahoma Oregon | |
Pennsylvania RhodeIsland SouthCarolina SouthDakota Tennessee Texas Utah | |
Vermont Virginia Washington WestVirginia Wisconsin Wyoming) | |
ARGV.each do |word| | |
states.each do |state| |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function($) { | |
// add a button for it | |
$('.Message a[href*="View.html?Post="]') | |
.after($('<span class="messagePreview">…</span>')); | |
// make the buttons work | |
$('.messagePreview').click(function(evt) { | |
console.log("Previewing message..."); | |
var postID = $(evt.target).parent() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--ExpBot II (Experimental Bot V2.1) - An simple IRC bot written in Lua - the programming language. | |
-- Comments are written in the luadoc style | |
-- http://keplerproject.github.io/luadoc/manual.html#tags | |
require "socket" | |
s = socket.tcp() | |
-- passwords are received from standard input | |
passLine = io.read() | |
network = "chat.eu.freenode.net" -- |