Skip to content

Instantly share code, notes, and snippets.

View madelinecr's full-sized avatar
:octocat:
Octocatting

Finn madelinecr

:octocat:
Octocatting
View GitHub Profile
diff --git a/Depot.cpp b/Depot.cpp
index 6083658..b6f2c66 100644
--- a/Depot.cpp
+++ b/Depot.cpp
@@ -5,6 +5,7 @@
#include "Depot.h"
#include <fstream>
#include <iostream>
+#include <algorithm>
using std::ifstream;
λ ~/Desktop/ ssh rimmer.no.ip.biz
ssh: Could not resolve hostname rimmer.no.ip.biz: Name or service not known
λ ~/Desktop/ ping rimmer.no.ip.biz
ping: unknown host rimmer.no.ip.biz
λ ~/Desktop/ whois rimmer.no.ip.biz
Not found: rimmer.no.ip.biz
>>>> Whois database was last updated on: Fri Jan 24 08:33:22 GMT 2014 <<<<
NeuStar, Inc., the Registry Operator for .BIZ, has collected this information
λ ~/ ps auwx | grep banshee
sensae 1438 214 3.0 2094220 122920 ? Sl Jun10 8520:00 banshee /usr/lib/banshee/Banshee.exe --redirect-log --play-enqueued
module Utilities
def method
puts "Namespaced hello world"
end
end
Utilities::method()
@madelinecr
madelinecr / xkcd_scraper.rb
Created March 4, 2013 08:25
xkcd_scraper
#!/usr/bin/env ruby
require 'open-uri'
require 'nokogiri'
@uri = "http://www.xkcd.com/"
@comics = Array.new
doc = Nokogiri::HTML(open("#{@uri}/archive"))
doc.xpath('//div[@id="middleContainer"]/a').each do |link|
@madelinecr
madelinecr / index.js
Last active December 14, 2015 05:39 — forked from anonymous/index.html
A very rudimentary binary search tree in Javascript
var tree = new Tree();
function Node(value) {
this.value = value;
this.left = null;
this.right = null;
}
function Tree() {
this.head = null;
sensae at SHODAN in /mnt
$ ls
initrd.gz ldlinux.sys syslinux.cfg vmlinuz
sensae at SHODAN in /mnt
$ du -h
7.6M .
pi@raspberrypi:~$ free -m
total used free shared buffers cached
Mem: 215 127 87 0 18 79
-/+ buffers/cache: 29 185
Swap: 0 0 0
pi@raspberrypi:~$ df -h
Filesystem Size Used Avail Use% Mounted on
tmpfs 108M 0 108M 0% /lib/init/rw
udev 10M 152K 9.9M 2% /dev
require 'spec_helper'
describe "Static pages" do
describe "Home page" do
before { visit '/static_pages/home' }
specify { page.should have_selector('h1', :text => 'Sample App')
specify { page.should have_selector('title', :text => "Ruby on Rails Tutorial Sample App | Home")
end
quicksort :: Ord a => [a] -> [a]
quicksort [] = []
quicksort (p:xs) = (quicksort lesser) ++ [p] ++ (quicksort greater)
where
lesser = filter (< p) xs
greater = filter (>= p) xs